diff options
author | AlTech98 <altech123159@gmail.com> | 2021-09-13 17:32:31 +0200 |
---|---|---|
committer | AlTech98 <altech123159@gmail.com> | 2021-09-13 17:32:31 +0200 |
commit | b438a21b9c252ace62f9ce803bae939cbc1677e3 (patch) | |
tree | 89367fdebb4f2592b5183047b04ec4259daeaaf3 /cdn/src/util | |
parent | Fix attachments not being saved to db (diff) | |
download | server-b438a21b9c252ace62f9ce803bae939cbc1677e3.tar.xz |
Delete attachments of deleted messages, fix #273
Diffstat (limited to 'cdn/src/util')
-rw-r--r-- | cdn/src/util/FileStorage.ts | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/cdn/src/util/FileStorage.ts b/cdn/src/util/FileStorage.ts index fae6eb1a..e0b24a84 100644 --- a/cdn/src/util/FileStorage.ts +++ b/cdn/src/util/FileStorage.ts @@ -37,6 +37,7 @@ export class FileStorage implements Storage { } async delete(path: string) { + //TODO we should delete the parent directory if empty fs.unlinkSync(getPath(path)); } } |