Skip to content

Sync-in · Sovereign platform for file storage, sharing, synchronization, and collaboration.

fix(frontend:files): unlock extensionless text files on viewer close

johaven9595153737bc
diff --git a/frontend/src/app/applications/files/components/dialogs/files-viewer-dialog.component.ts b/frontend/src/app/applications/files/components/dialogs/files-viewer-dialog.component.ts
index 49e676e8..1d05d582 100644
--- a/frontend/src/app/applications/files/components/dialogs/files-viewer-dialog.component.ts
+++ b/frontend/src/app/applications/files/components/dialogs/files-viewer-dialog.component.ts
@@ -66,7 +66,7 @@ export class FilesViewerDialogComponent implements OnInit, OnDestroy {
}
onClose() {
- if (this.currentFile.isEditable && (this.hookedShortMime === SHORT_MIME.TEXT || this.hookedShortMime === SHORT_MIME.MARKDOWN)) {
+ if (this.hookedShortMime === SHORT_MIME.TEXT || this.hookedShortMime === SHORT_MIME.MARKDOWN) {
// Prevent closing the modal without saving when using text-based editors
this.modalClosing.set(true)
// Force the next state change