aboutsummaryrefslogtreecommitdiff
path: root/src/auth.ts
diff options
context:
space:
mode:
authorjw2552018-03-06 16:50:03 +0000
committerjw2552018-03-06 16:50:03 +0000
commitf3491957d8599a7ba97d9cb324274df49b6fdbd0 (patch)
tree98fbc253b0f5d3f140450b339d01da1c8055b052 /src/auth.ts
parentMerge branch 'trh/payload-checker' into testing-middleware (diff)
downloadmedicine-f3491957d8599a7ba97d9cb324274df49b6fdbd0.tar.gz
medicine-f3491957d8599a7ba97d9cb324274df49b6fdbd0.zip

authentication tests

Diffstat (limited to 'src/auth.ts')
-rw-r--r--src/auth.ts2
1 files changed, 0 insertions, 2 deletions
diff --git a/src/auth.ts b/src/auth.ts
index 5a1707c..6339260 100644
--- a/src/auth.ts
+++ b/src/auth.ts
@@ -112,9 +112,7 @@ export class AuthRouter {
// Handle error if user is unauthorised
export const unauthorisedErr: Errorware =
(err: Error, req: Request, res: Response, next: NextFunction): void => {
- console.log('fffff');
if (err.name === 'UnauthorizedError') {
- console.log('efewfwf');
return next(new RequestError(
401, 'not_authorised',
'user does not have correct authorisation for task'