Permalink
Browse files

Revert "Rack::Request has an #ssl? method that handles this case. cal…

…l that rather than reproducing its logic"

This reverts commit d6b1797, which
introduces an unspecified dependency on rack 1.3.

Closes #663.
  • Loading branch information...
1 parent 3e8aa2e commit 6d48f037b5f8c20884fddb0cf0531ef55666dd61 @sferik sferik committed Feb 13, 2013
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/omniauth/strategy.rb
View
2 lib/omniauth/strategy.rb
@@ -405,7 +405,7 @@ def full_host
uri.path = ''
uri.query = nil
#sometimes the url is actually showing http inside rails because the other layers (like nginx) have handled the ssl termination.
- uri.scheme = 'https' if request.ssl?
+ uri.scheme = 'https' if(request.env['HTTP_X_FORWARDED_PROTO'] == 'https')
uri.to_s
end
end

0 comments on commit 6d48f03

Please sign in to comment.