Method: Stackify::AuthWorker#after_perform

Defined in:
lib/stackify/workers/auth_worker.rb

#after_perform(result) ⇒ Object



9
10
11
12
13
14
15
16
# File 'lib/stackify/workers/auth_worker.rb', line 9

def after_perform result
  if result.try(:code) == '200'
    Stackify.send :authorized!
    Stackify.successfull_authorisation result
  else
    Stackify.unsuccessfull_authorisation result, self
  end
end