test
This commit is contained in:
parent
5ee37f32e2
commit
4518fe4355
|
@ -15,6 +15,7 @@ module Mobile
|
||||||
raise('Unauthorized. Invalid or expired token.') unless current_user
|
raise('Unauthorized. Invalid or expired token.') unless current_user
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
def current_user
|
def current_user
|
||||||
token = ApiKey.where(access_token: params[:token]).first
|
token = ApiKey.where(access_token: params[:token]).first
|
||||||
if token && !token.expired?
|
if token && !token.expired?
|
||||||
|
|
Loading…
Reference in New Issue