Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add compiler flag to disable UIApplication calls #280

Merged
merged 4 commits into from
Aug 28, 2018

Conversation

MaximeLM
Copy link
Contributor

Fixes #275 with the solution initially proposed in #133.

App extensions users will be able to add a P2_APP_EXTENSIONS compiler flag to the p2.OAuth2 target to disable UIApplication calls.

@p2
Copy link
Owner

p2 commented Aug 23, 2018

Cool, thanks! Just 1 thing: can you make an #else and throw OAuth2Error.unableToOpenAuthorizeURL?

@MaximeLM
Copy link
Contributor Author

Done

@p2
Copy link
Owner

p2 commented Aug 24, 2018

Thanks! And I just realized, with this compiler flag, we no longer need the comment and the workaround to get the UIApp instance via sharedApplication by key, is that right? If so, can you also clean that code up and remove the comment?

@MaximeLM
Copy link
Contributor Author

Ok, that's done!

@p2
Copy link
Owner

p2 commented Aug 27, 2018

Great, thanks! Did you want to add your name as mentioned in CONTRIBUTING.md or shall I merge now?

@MaximeLM
Copy link
Contributor Author

I've added myself as a contributor, you can merge.

@p2 p2 merged commit fb4d26e into p2:develop Aug 28, 2018
@MaximeLM MaximeLM deleted the app_extension_flag branch August 28, 2018 16:09
ajandrade added a commit to sensational/OAuth2 that referenced this pull request Oct 14, 2020
* commit '0efd11a669aba0f7c8ed2946e93757bb3dfdd6a6':
  Update Travis config
  Update project settings and CHANGELOG
  Improve documentation
  Fix compilation errors and warnings from PKCE merge
  Add refresh uri setting (p2#330)
  Mac Catalyst support (p2#328)
  Changed autorizeContext var to weak (p2#329)
  Add PKCE support (p2#324)
  Update Swift package manager configuration (p2#322)
  Update to Swift 5
  Fix compile errors with Swift 5 (p2#313)
  Update README.md
  Add support for Authentication Session (p2#305)
  Update version in sample configurations of the README to 4.2
  Use bundler for generating docs
  Set podspec version to 4.2.0
  Add compiler flag to disable UIApplication calls (p2#280)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants