Skip to content

Commit 112ecf8

Browse files
author
Damien Rambout
committed
Add guard to unsupported features of iOS 8 extensions
1 parent a923a0a commit 112ecf8

File tree

3 files changed

+19
-7
lines changed

3 files changed

+19
-7
lines changed

OAuth2Client.xcodeproj/project.pbxproj

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,8 @@
8383
/* End PBXBuildFile section */
8484

8585
/* Begin PBXFileReference section */
86+
3E3000541DC3FD5BCDC62EBC /* Pods-OAuth2ClientTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-OAuth2ClientTests.release.xcconfig"; path = "Pods/Target Support Files/Pods-OAuth2ClientTests/Pods-OAuth2ClientTests.release.xcconfig"; sourceTree = "<group>"; };
8687
824D5A6D123F68A8001177D5 /* NXOAuth2ClientDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NXOAuth2ClientDelegate.h; sourceTree = "<group>"; };
87-
83DD991B6049465CB61E135B /* Pods-OAuth2ClientTests.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-OAuth2ClientTests.xcconfig"; path = "Pods/Pods-OAuth2ClientTests.xcconfig"; sourceTree = "<group>"; };
8888
9404FAC1123E3A6900397DD1 /* NXOAuth2.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NXOAuth2.h; sourceTree = "<group>"; };
8989
9429B3A812267A3100D31807 /* NXOAuth2Client.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NXOAuth2Client.h; sourceTree = "<group>"; };
9090
9429B3A912267A3100D31807 /* NXOAuth2Client.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = NXOAuth2Client.m; sourceTree = "<group>"; };
@@ -117,6 +117,7 @@
117117
99F08DE9138BE8CE002A5401 /* NXOAuth2TrustDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NXOAuth2TrustDelegate.h; sourceTree = "<group>"; };
118118
AA747D9E0F9514B9006C5449 /* OAuth2Client_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = OAuth2Client_Prefix.pch; sourceTree = "<group>"; };
119119
AACBBE490F95108600F1A2B1 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
120+
B41D0679A4B0343F646C29DC /* Pods-OAuth2ClientTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-OAuth2ClientTests.debug.xcconfig"; path = "Pods/Target Support Files/Pods-OAuth2ClientTests/Pods-OAuth2ClientTests.debug.xcconfig"; sourceTree = "<group>"; };
120121
B9E2089E9E7941B7AF3D27AA /* libPods-OAuth2ClientTests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-OAuth2ClientTests.a"; sourceTree = BUILT_PRODUCTS_DIR; };
121122
D2AAC07E0554694100DB518D /* libOAuth2Client.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libOAuth2Client.a; sourceTree = BUILT_PRODUCTS_DIR; };
122123
F6525B4313D593C900ACAE8F /* NXOAuth2Account+Private.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NXOAuth2Account+Private.h"; sourceTree = SOURCE_ROOT; };
@@ -181,7 +182,7 @@
181182
0867D69AFE84028FC02AAC07 /* Frameworks */,
182183
034768DFFF38A50411DB9C8B /* Products */,
183184
942FFCDE12315E2E00E6C65E /* Resources */,
184-
83DD991B6049465CB61E135B /* Pods-OAuth2ClientTests.xcconfig */,
185+
B8D5E78C3AD14156E0A3E07C /* Pods */,
185186
);
186187
name = OAuth2Client;
187188
sourceTree = "<group>";
@@ -275,6 +276,15 @@
275276
path = Tests;
276277
sourceTree = "<group>";
277278
};
279+
B8D5E78C3AD14156E0A3E07C /* Pods */ = {
280+
isa = PBXGroup;
281+
children = (
282+
B41D0679A4B0343F646C29DC /* Pods-OAuth2ClientTests.debug.xcconfig */,
283+
3E3000541DC3FD5BCDC62EBC /* Pods-OAuth2ClientTests.release.xcconfig */,
284+
);
285+
name = Pods;
286+
sourceTree = "<group>";
287+
};
278288
F6E1A11313D7128100B6DAC3 /* Private */ = {
279289
isa = PBXGroup;
280290
children = (
@@ -488,7 +498,7 @@
488498
);
489499
runOnlyForDeploymentPostprocessing = 0;
490500
shellPath = /bin/sh;
491-
shellScript = "\"${SRCROOT}/Pods/Pods-OAuth2ClientTests-resources.sh\"\n";
501+
shellScript = "\"${SRCROOT}/Pods/Target Support Files/Pods-OAuth2ClientTests/Pods-OAuth2ClientTests-resources.sh\"\n";
492502
showEnvVarsInLog = 0;
493503
};
494504
/* End PBXShellScriptBuildPhase section */
@@ -674,7 +684,7 @@
674684
};
675685
94B6CE6C19C1D0A300AA859B /* Debug */ = {
676686
isa = XCBuildConfiguration;
677-
baseConfigurationReference = 83DD991B6049465CB61E135B /* Pods-OAuth2ClientTests.xcconfig */;
687+
baseConfigurationReference = B41D0679A4B0343F646C29DC /* Pods-OAuth2ClientTests.debug.xcconfig */;
678688
buildSettings = {
679689
ALWAYS_SEARCH_USER_PATHS = NO;
680690
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
@@ -720,7 +730,7 @@
720730
};
721731
94B6CE6D19C1D0A300AA859B /* Release */ = {
722732
isa = XCBuildConfiguration;
723-
baseConfigurationReference = 83DD991B6049465CB61E135B /* Pods-OAuth2ClientTests.xcconfig */;
733+
baseConfigurationReference = 3E3000541DC3FD5BCDC62EBC /* Pods-OAuth2ClientTests.release.xcconfig */;
724734
buildSettings = {
725735
ALWAYS_SEARCH_USER_PATHS = NO;
726736
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";

Podfile.lock

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ PODS:
22
- Expecta (0.3.1)
33
- OCMock (3.1.1)
44
- OHHTTPStubs (3.1.5):
5-
- OHHTTPStubs/Core
5+
- OHHTTPStubs/Core (= 3.1.5)
66
- OHHTTPStubs/Core (3.1.5)
77
- Specta (0.2.1)
88

@@ -18,4 +18,4 @@ SPEC CHECKSUMS:
1818
OHHTTPStubs: c1e362552b71b81e1deb7a80f44c51585b946c43
1919
Specta: 9141310f46b1f68b676650ff2854e1ed0b74163a
2020

21-
COCOAPODS: 0.33.1
21+
COCOAPODS: 0.36.1

Sources/OAuth2Client/NXOAuth2AccountStore.m

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -461,6 +461,7 @@ - (NSString *)accountTypeOfPendingOAuthClient:(NXOAuth2Client *)oauthClient;
461461

462462
- (void)oauthClientNeedsAuthentication:(NXOAuth2Client *)client;
463463
{
464+
#if !defined(NX_APP_EXTENSIONS)
464465
NSString *accountType = [self accountTypeOfPendingOAuthClient:client];
465466

466467
NSDictionary *configuration;
@@ -476,6 +477,7 @@ - (void)oauthClientNeedsAuthentication:(NXOAuth2Client *)client;
476477
#else
477478
[[NSWorkspace sharedWorkspace] openURL:preparedURL];
478479
#endif
480+
#endif
479481
}
480482

481483
- (void)oauthClientDidGetAccessToken:(NXOAuth2Client *)client;

0 commit comments

Comments
 (0)