diff --git a/src/backend/src/middleware/configurable_auth.js b/src/backend/src/middleware/configurable_auth.js index 04fdfa5f..1f61f953 100644 --- a/src/backend/src/middleware/configurable_auth.js +++ b/src/backend/src/middleware/configurable_auth.js @@ -59,9 +59,9 @@ const configurable_auth = options => async (req, res, next) => { token = req.header('Authorization'); token = token.replace('Bearer ', '').trim(); if ( token === 'undefined' ) { - APIError.create('unexpected_undefined', null, - `The Authorization token cannot be the string "undefined"` - ); + APIError.create('unexpected_undefined', null, { + msg: `The Authorization token cannot be the string "undefined"` + }); } } // Cookie