High performance self-hosted photo and video management solution.
TypeScript backup-toolfluttergoogle-photosgoogle-photos-alternativejavascriptmobile-appnestjsnodejsphoto-galleryphotosphotos-managementself-hostedsveltesveltekittypescriptvideos
fix(server): folder sort order (#21383)
Sergey Katsubo460e1d4715a9
diff --git a/server/src/queries/view.repository.sql b/server/src/queries/view.repository.sqlindex 81f5ca20b8..31da10123f 100644--- a/server/src/queries/view.repository.sql+++ b/server/src/queries/view.repository.sql@@ -12,6 +12,8 @@ whereand "fileCreatedAt" is not nulland "fileModifiedAt" is not nulland "localDateTime" is not null+order by+ "directoryPath" asc-- ViewRepository.getAssetsByOriginalPathselectdiff --git a/server/src/repositories/view-repository.ts b/server/src/repositories/view-repository.tsindex 93c1280191..ceab79f6eb 100644--- a/server/src/repositories/view-repository.ts+++ b/server/src/repositories/view-repository.ts@@ -20,6 +20,7 @@ export class ViewRepository {.where('fileCreatedAt', 'is not', null).where('fileModifiedAt', 'is not', null).where('localDateTime', 'is not', null)+ .orderBy('directoryPath', 'asc').execute();return results.map((row) => row.directoryPath.replaceAll(/\/$/g, ''));