Class: Zetto::Services::Session::GetUser
- Inherits:
-
Object
- Object
- Zetto::Services::Session::GetUser
- Defined in:
- lib/zetto/services/session/get_user.rb
Instance Method Summary collapse
- #execute ⇒ Object
-
#initialize(cookies, user_agent, remote_ip) ⇒ GetUser
constructor
A new instance of GetUser.
Constructor Details
#initialize(cookies, user_agent, remote_ip) ⇒ GetUser
Returns a new instance of GetUser.
5 6 7 8 9 10 11 12 13 |
# File 'lib/zetto/services/session/get_user.rb', line 5 def initialize(, user_agent, remote_ip) unless .class.to_s == "ActionDispatch::Cookies::CookieJar" raise ArgumentError.new(I18n.t('exseptions.save_session_cookies')) end = @user_agent = user_agent @remote_ip = remote_ip end |
Instance Method Details
#execute ⇒ Object
15 16 17 18 19 20 |
# File 'lib/zetto/services/session/get_user.rb', line 15 def execute rescue Exception => e Zetto::Services::Info. I18n.t('exseptions.unknown_error', argument: 'Zetto::Services::Session::GetUser', current_method: __method__), e nil end |