forked from cloudron-apps/gitea-app
fix api usage
This commit is contained in:
parent
a7e693c4ed
commit
f9949c11a3
1 changed files with 1 additions and 1 deletions
|
@ -253,7 +253,7 @@ return done();
|
||||||
|
|
||||||
token = result.body.accessToken;
|
token = result.body.accessToken;
|
||||||
|
|
||||||
superagent.get('https://' + inspect.apiEndpoint + '/api/v1/user/profile')
|
superagent.get('https://' + inspect.apiEndpoint + '/api/v1/profile')
|
||||||
.query({ access_token: token }).end(function (error, result) {
|
.query({ access_token: token }).end(function (error, result) {
|
||||||
if (error) return done(error);
|
if (error) return done(error);
|
||||||
if (result.statusCode !== 200) return done(new Error('Get profile failed with status ' + result.statusCode));
|
if (result.statusCode !== 200) return done(new Error('Get profile failed with status ' + result.statusCode));
|
||||||
|
|
Loading…
Reference in a new issue