Commit e9c35609 authored by Valeriy Sizov's avatar Valeriy Sizov
Browse files

#1606 API private token via the header

parent 5dad4a325f1c
module Gitlab
module APIHelpers
def current_user
@current_user ||= User.find_by_authentication_token(params[:private_token])
@current_user ||= User.find_by_authentication_token(params[:private_token] || header[:private_token])
def user_project
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment