rack-webauth 0.1.2 → 0.1.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -43,21 +43,14 @@ class Rack::Webauth::WardenStrategy < Warden::Strategies::Base
43
43
  include Rack::Webauth::Helpers
44
44
 
45
45
  def valid?
46
- webauth
47
- true
48
- rescue Rack::Webauth::Info::NotAvailable
49
- false
46
+ webauth.logged_in?
50
47
  end
51
48
 
52
49
  def authenticate!
53
- if webauth.logged_in?
54
- if user = instance_eval(&self.class.finder)
55
- success!(user)
56
- else
57
- fail!(:invalid)
58
- end
50
+ if user = instance_eval(&self.class.finder)
51
+ success!(user)
59
52
  else
60
- fail!
53
+ fail!(:invalid)
61
54
  end
62
55
  end
63
56
  end
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rack-webauth
3
3
  version: !ruby/object:Gem::Version
4
- hash: 31
4
+ hash: 29
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 1
9
- - 2
10
- version: 0.1.2
9
+ - 3
10
+ version: 0.1.3
11
11
  platform: ruby
12
12
  authors:
13
13
  - Niklas E. Cathor