Use standard API to read cookies

#700
This commit is contained in:
Artur Beljajev 2018-02-14 01:24:12 +02:00
parent c97e651398
commit 0ee32549f0

View file

@ -86,11 +86,8 @@ class EppController < ApplicationController
@params_hash ||= Hash.from_xml(params[:frame]).with_indifferent_access
end
# SESSION MANAGEMENT
def epp_session
cookies # Probably does some initialization
cookie = env['rack.request.cookie_hash'] || {}
EppSession.find_or_initialize_by(session_id: cookie['session'])
EppSession.find_by(session_id: epp_session_id)
end
def update_epp_session