Skip to content
This repository has been archived by the owner on Jan 26, 2024. It is now read-only.

Commit

Permalink
Fix Update authContext smart-on-fhir#33
Browse files Browse the repository at this point in the history
  • Loading branch information
ementele committed Jul 23, 2020
1 parent f5d2830 commit 6ca5c5a
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 6 deletions.
2 changes: 1 addition & 1 deletion CONTRIBUTORS.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@ Contributors

Contributors to the codebase, in reverse chronological order:

- Eric Mentele, @EricMentele
- Dave Carlson, @drdavec
- Pascal Pfiffner, @p2

4 changes: 2 additions & 2 deletions Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@
<key>CFBundlePackageType</key>
<string>FMWK</string>
<key>CFBundleShortVersionString</key>
<string>4.2.0</string>
<string>$(MARKETING_VERSION)</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>4.2.0.0</string>
<string>$(CURRENT_PROJECT_VERSION)</string>
<key>NSPrincipalClass</key>
<string></string>
</dict>
Expand Down
4 changes: 3 additions & 1 deletion Sources/iOS/Auth+iOS.swift
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,9 @@ extension Auth {
- parameter callback: The callback that is called when authorization completes or fails
*/
func authorize(with oauth: OAuth2, properties: SMARTAuthProperties, callback: @escaping ((OAuth2JSON?, OAuth2Error?) -> Void)) {
authContext = UIApplication.shared.keyWindow?.rootViewController

let rootViewController = UIApplication.shared.keyWindow?.rootViewController
authContext = rootViewController?.presentedViewController ?? rootViewController

oauth.authConfig.authorizeContext = authContext
oauth.authConfig.authorizeEmbedded = properties.embedded
Expand Down
6 changes: 4 additions & 2 deletions SwiftSMART.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -555,7 +555,7 @@
isa = XCBuildConfiguration;
buildSettings = {
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "";
CURRENT_PROJECT_VERSION = 1;
CURRENT_PROJECT_VERSION = 4.2.1.0;
DEFINES_MODULE = YES;
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
Expand All @@ -567,6 +567,7 @@
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
MARKETING_VERSION = 4.2.1;
METAL_ENABLE_DEBUG_INFO = YES;
"OTHER_SWIFT_FLAGS[arch=*]" = "-DDEBUG -DNO_MODEL_IMPORT -DNO_MODULE_IMPORT -DNO_KEYCHAIN_IMPORT";
PRODUCT_BUNDLE_IDENTIFIER = "org.chip.${PRODUCT_NAME:rfc1034identifier}";
Expand All @@ -584,7 +585,7 @@
isa = XCBuildConfiguration;
buildSettings = {
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "";
CURRENT_PROJECT_VERSION = 1;
CURRENT_PROJECT_VERSION = 4.2.1.0;
DEFINES_MODULE = YES;
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
Expand All @@ -596,6 +597,7 @@
"@executable_path/Frameworks",
"@loader_path/Frameworks",
);
MARKETING_VERSION = 4.2.1;
METAL_ENABLE_DEBUG_INFO = NO;
"OTHER_SWIFT_FLAGS[arch=*]" = "-DNO_MODEL_IMPORT -DNO_KEYCHAIN_IMPORT -DNO_MODULE_IMPORT";
PRODUCT_BUNDLE_IDENTIFIER = "org.chip.${PRODUCT_NAME:rfc1034identifier}";
Expand Down

0 comments on commit 6ca5c5a

Please sign in to comment.