rack-oauth_echo 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -8,8 +8,8 @@ module Rack
8
8
  end
9
9
 
10
10
  def call(env)
11
- if valid_header?(env)
12
- json_response = auth_request(env) if valid_header?(env)
11
+ if auth_header?(env)
12
+ json_response = auth_request(env)
13
13
  if json_response.status == 200
14
14
  env['rack-oauth_echo.user_hash'] = auth_request(env).body
15
15
  @app.call(env)
@@ -23,7 +23,7 @@ module Rack
23
23
 
24
24
  private
25
25
 
26
- def valid_header?(env)
26
+ def auth_header?(env)
27
27
  env.has_key?('X-Verify-Credentials-Authorization') ||
28
28
  env.has_key?('X-Auth-Service-Provider')
29
29
  end
@@ -1,5 +1,5 @@
1
1
  module Rack
2
2
  module OAuthEcho
3
- VERSION = "0.0.1"
3
+ VERSION = "0.0.2"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rack-oauth_echo
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: