Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Strip whitespace from authentication token.
My token had a newline in the file, resulting in the following HTTP request being made to Github: ``` GET /user HTTP/1.1 Host: api.github.com Connection: Keep-Alive authorization: token xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx content-type: application/x-www-form-urlencoded accept: */* user-agent: Nim httpclient/0.19.9 ``` Unfortunately the friendly error message returned by the Github server is lost in translation because getContent() throws an exception, never handling the body.
- Loading branch information