aboutsummaryrefslogtreecommitdiff
path: root/src/FileRouter.ts
diff options
context:
space:
mode:
authorcjd242018-04-26 07:02:02 +0100
committercjd242018-04-26 07:02:02 +0100
commit025b4833009255baba8a24be4dde78c0f0832fb2 (patch)
tree22fa76dfbd6cf33669a280373dacc74c35c0e7d3 /src/FileRouter.ts
parentfixing czi live tiles and adding support for scn live tiles (diff)
parentMerge branch 'trh/gets' of gitlab.cs.st-andrews.ac.uk:cs3099group-be-4/projec... (diff)
downloadmedicine-025b4833009255baba8a24be4dde78c0f0832fb2.tar.gz
medicine-025b4833009255baba8a24be4dde78c0f0832fb2.zip

Merge branch ‘trh/gets’ of https://gitlab.cs.st-andrews.ac.uk/cs3099group-be-4/project-code into trh/gets

Diffstat (limited to 'src/FileRouter.ts')
-rw-r--r--src/FileRouter.ts5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/FileRouter.ts b/src/FileRouter.ts
index 35d3977..957b596 100644
--- a/src/FileRouter.ts
+++ b/src/FileRouter.ts
@@ -569,7 +569,7 @@ const postProjectName: Middleware = async(
}
});
if (ujp != null) {
- logger.debug(`Removing ${req.body.username}'s old privileges in ${project.name}`);
+ logger.debug(`Removing ${req.body.username}'s old privileges in ${project.name}`);
await ujp.destroy();
}
if (req.body.access_level !== 'none') {
@@ -851,7 +851,7 @@ const postFilePath: Middleware = async(
if (res.locals.file) {
/* tslint:disable-next-line:curly */
- if (req.query.action) switch (req.query.action) {
+ if (req.query.action && req.query.action !== 'upload') switch (req.query.action) {
case 'set_metadata': {
res.locals.file.metadata = JSON.parse(req.body.toString());
await res.locals.file.save();
@@ -934,7 +934,6 @@ const postFilePath: Middleware = async(
}
}
} else {
- /* tslint:disable-next-line:curly */
if (req.query.action) {
switch (req.query.action) {
case 'mkdir': {