Fix superagent use
This commit is contained in:
@@ -16,7 +16,8 @@ exports.up = async function(db) {
|
||||
const response = await superagent.post(`${apiServerOrigin}/api/v1/user_token`)
|
||||
.send({})
|
||||
.query({ accessToken: apiToken })
|
||||
.timeout(30 * 1000);
|
||||
.timeout(30 * 1000)
|
||||
.ok(() => true);
|
||||
|
||||
if (response.status !== 201 || !response.body.accessToken) {
|
||||
console.log(`Bad status getting web token: ${response.status} ${response.text}`);
|
||||
|
||||
Reference in New Issue
Block a user