Skip to content

Commit 0883595

Browse files
committed
refactor: fix lint warning on lib/response.js
Signed-off-by: BoHong Li <[email protected]>
1 parent b0dee3e commit 0883595

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

lib/response.js

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ var utils = require('./utils')
1818
// public
1919
var response = {
2020
errorForbidden: function (res) {
21-
const {req} = res
21+
const { req } = res
2222
if (req.user) {
2323
responseError(res, '403', 'Forbidden', 'oh no.')
2424
} else {
@@ -549,16 +549,16 @@ function gitlabActionProjects (req, res, note) {
549549
ret.accesstoken = user.accessToken
550550
ret.profileid = user.profileid
551551
request(
552-
config.gitlab.baseURL + '/api/' + config.gitlab.version + '/projects?membership=yes&per_page=100&access_token=' + user.accessToken,
553-
function (error, httpResponse, body) {
554-
if (!error && httpResponse.statusCode === 200) {
555-
ret.projects = JSON.parse(body)
556-
return res.send(ret)
557-
} else {
558-
return res.send(ret)
559-
}
560-
}
561-
)
552+
config.gitlab.baseURL + '/api/' + config.gitlab.version + '/projects?membership=yes&per_page=100&access_token=' + user.accessToken,
553+
function (error, httpResponse, body) {
554+
if (!error && httpResponse.statusCode === 200) {
555+
ret.projects = JSON.parse(body)
556+
return res.send(ret)
557+
} else {
558+
return res.send(ret)
559+
}
560+
}
561+
)
562562
}).catch(function (err) {
563563
logger.error('gitlab action projects failed: ' + err)
564564
return response.errorInternalError(res)

0 commit comments

Comments
 (0)