mirror of
https://github.com/gitbutlerapp/gitbutler.git
synced 2024-09-11 12:25:42 +03:00
🔨 Refactor: Sort sessions by startTimestampMs
- Sort project sessions by startTimestampMs - Update layout for project routes [src/routes/projects/[projectId]/+layout.ts] - Sort sessions by startTimestampMs
This commit is contained in:
parent
4f78da2464
commit
5b98e24ea7
@ -13,7 +13,9 @@ export const load: LayoutLoad = async ({ parent, params }) => {
|
||||
await import("$lib/sessions")
|
||||
).default({ projectId: params.projectId });
|
||||
const orderedSessions = derived(sessions, (sessions) => {
|
||||
return sessions.slice().sort((a, b) => a.meta.startTimestampMs - b.meta.startTimestampMs);
|
||||
return sessions
|
||||
.slice()
|
||||
.sort((a, b) => a.meta.startTimestampMs - b.meta.startTimestampMs);
|
||||
});
|
||||
return {
|
||||
project: projects.get(params.projectId),
|
||||
|
Loading…
Reference in New Issue
Block a user