mirror of
https://github.com/plankanban/planka.git
synced 2025-12-20 01:14:12 +03:00
feat: Track storage usage
This commit is contained in:
@@ -51,13 +51,11 @@ module.exports = {
|
||||
});
|
||||
}
|
||||
|
||||
const { attachment, fileReference } = await Attachment.qm.deleteOne(inputs.record.id, {
|
||||
isFile: inputs.record.type === Attachment.Types.FILE,
|
||||
});
|
||||
const { attachment, uploadedFile } = await Attachment.qm.deleteOne(inputs.record.id);
|
||||
|
||||
if (attachment) {
|
||||
if (fileReference) {
|
||||
sails.helpers.attachments.removeUnreferencedFiles(fileReference);
|
||||
if (uploadedFile) {
|
||||
sails.helpers.utils.removeUnreferencedUploadedFiles(uploadedFile);
|
||||
}
|
||||
|
||||
sails.sockets.broadcast(
|
||||
|
||||
Reference in New Issue
Block a user