From 1e658d9cc21aa294d36eafebbf77cdc30a323726 Mon Sep 17 00:00:00 2001 From: Tobias de Bruijn Date: Thu, 22 Feb 2024 14:18:18 +0100 Subject: [PATCH] Bugfixes - Fix: Upload button could be pressed while already uploading - Fix: Sort by createdAt rather than publishedAt to avoid DRAFT albums being at the bottom Signed-off-by: Tobias de Bruijn --- frontend/src/components/UploadPhotoDialog.vue | 1 + frontend/src/views/album/AlbumGridView.vue | 6 +----- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/frontend/src/components/UploadPhotoDialog.vue b/frontend/src/components/UploadPhotoDialog.vue index 90275e2..74f27fe 100644 --- a/frontend/src/components/UploadPhotoDialog.vue +++ b/frontend/src/components/UploadPhotoDialog.vue @@ -30,6 +30,7 @@ Upload diff --git a/frontend/src/views/album/AlbumGridView.vue b/frontend/src/views/album/AlbumGridView.vue index 5c129f4..91d4a48 100644 --- a/frontend/src/views/album/AlbumGridView.vue +++ b/frontend/src/views/album/AlbumGridView.vue @@ -123,11 +123,7 @@ export default Vue.extend({ // Sort in descending chronological order -- Newest albums first albums.sort((a, b) => { - if(a.publishedAt != null && b.publishedAt != null) { - return b.publishedAt - a.publishedAt; - } else { - return b.createdAt - a.createdAt; - } + return b.createdAt - a.createdAt; }); this.albums = albums;