Created
April 13, 2018 15:12
-
-
Save jonajgs/b28f0580fbbf94a47684837c8ad7a038 to your computer and use it in GitHub Desktop.
how get the header's token
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
this.http.get(this._url, {search: params}).map((res: Response) => { | |
if(res.headers && res.headers.get('Token')) { | |
var token = res.headers.get('Token'); | |
} | |
return res.json() | |
}).catch(function(error) { | |
return Observable.throw(error.json()); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment