summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarie <marie@kaifa.ch>2024-02-13 22:01:53 +0000
committerMarie <marie@kaifa.ch>2024-02-13 22:01:53 +0000
commit8f6dfa611ef6f5fd6fa68bb5108573f7cb9e34b4 (patch)
treef856d50238658ddd7b83411fe911989204b11878
parentmerge: Never return broken notifications #409 (!415) (diff)
downloadsharkey-8f6dfa611ef6f5fd6fa68bb5108573f7cb9e34b4.tar.gz
sharkey-8f6dfa611ef6f5fd6fa68bb5108573f7cb9e34b4.tar.bz2
sharkey-8f6dfa611ef6f5fd6fa68bb5108573f7cb9e34b4.zip
fix: keep alt text of file if present
-rw-r--r--packages/backend/src/queue/processors/ImportNotesProcessorService.ts4
1 files changed, 4 insertions, 0 deletions
diff --git a/packages/backend/src/queue/processors/ImportNotesProcessorService.ts b/packages/backend/src/queue/processors/ImportNotesProcessorService.ts
index b772578b33..f79ecb419a 100644
--- a/packages/backend/src/queue/processors/ImportNotesProcessorService.ts
+++ b/packages/backend/src/queue/processors/ImportNotesProcessorService.ts
@@ -419,6 +419,10 @@ export class ImportNotesProcessorService {
const name = file.url.substring(slashdex + 1);
const exists = await this.driveFilesRepository.findOneBy({ name: name, userId: user.id });
if (exists) {
+ if (file.name) {
+ this.driveService.updateFile(exists, { comment: file.name }, user);
+ }
+
files.push(exists);
}
}