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

Fix configure issue #7

Merged
merged 2 commits into from
Apr 3, 2017
Merged

Fix configure issue #7

merged 2 commits into from
Apr 3, 2017

Conversation

ashkan18
Copy link
Contributor

@ashkan18 ashkan18 commented Apr 2, 2017

Problem

Configuring artsy_api_url in OmniAuth::Artsy doesn't change site in OmniAuth::Strategies::Artsy.

Solution

This is because of the fact that option method in Strategies::Artsy was called at load time and when we configure OmniAuth::Artsy it's too late and doesn't impact how strategy was setup. Not sure what's the best solution here, but I ended up:

  1. Move option call in OmniAuth::Strategies::Artsy to configure method and call it once during load time for existing users of this gem.
  2. Add reconfigure_strategy method to OmniAuth::Artsy which will be called after running configure block and will call configure method mentioned ☝️

@ashkan18 ashkan18 requested a review from dblock April 2, 2017 22:42
@dblock dblock merged commit d673f42 into artsy:master Apr 3, 2017
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.

None yet

2 participants