diff options
| author | josh97josh | 2018-04-16 18:03:59 +0100 |
|---|---|---|
| committer | josh97josh | 2018-04-16 18:03:59 +0100 |
| commit | fbef411bb1a0987a753024fc7822683fd3dc1df8 (patch) | |
| tree | 319a222ae9e49a2ca666413e2a98208107ee1e7b /src/FileRouter.ts | |
| parent | file upload works, i thnk (diff) | |
| download | medicine-fbef411bb1a0987a753024fc7822683fd3dc1df8.tar.gz medicine-fbef411bb1a0987a753024fc7822683fd3dc1df8.zip | |
minor errors fixed
Diffstat (limited to 'src/FileRouter.ts')
| -rw-r--r-- | src/FileRouter.ts | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/FileRouter.ts b/src/FileRouter.ts index 9a7dcac..ff8f5c1 100644 --- a/src/FileRouter.ts +++ b/src/FileRouter.ts @@ -367,6 +367,7 @@ const postCurUser: Middleware = async( const postUsername: Middleware = async( req: Request, res: Response, next: NextFunction ): Promise<void> => { + //if (req.query.action === 'create') let user: User | null | undefined = res.locals.user; res.locals.modified = true; if (user == null) { @@ -382,6 +383,7 @@ const postUsername: Middleware = async( if (req.body) { user.metadata = req.body; } + await user.save() next(); }; |
