set Authorization header
This commit is contained in:
parent
0ac50d038f
commit
ab3ca42c67
|
@ -30,4 +30,7 @@ jQuery.support.cors = true
|
|||
|
||||
ajax: (url, method, options) ->
|
||||
endpoint = Travis.config.api_endpoint || ''
|
||||
if Travis.config.access_token
|
||||
options.headers ||= {}
|
||||
options.headers['Authorization'] ||= "token #{Travis.config.access_token}"
|
||||
@_super("#{endpoint}#{url}", method, $.extend(options, @DEFAULT_OPTIONS))
|
||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue
Block a user