Module: Pathway::Plugins::SimpleAuth::InstanceMethods
- Defined in:
- lib/pathway/plugins/simple_auth.rb
Instance Method Summary collapse
Instance Method Details
#authorize(state, using: nil) ⇒ Object
13 14 15 |
# File 'lib/pathway/plugins/simple_auth.rb', line 13 def (state, using: nil) (state[using || result_key]).then { state } end |
#authorize_with(*objs) ⇒ Object
17 18 19 20 |
# File 'lib/pathway/plugins/simple_auth.rb', line 17 def (*objs) objs = objs.first if objs.size <= 1 (*objs) ? wrap(objs) : error(:forbidden) end |
#authorized?(*_) ⇒ Boolean
22 23 24 |
# File 'lib/pathway/plugins/simple_auth.rb', line 22 def (*_) true end |