mirror of
https://github.com/gitbutlerapp/gitbutler.git
synced 2024-11-24 05:29:51 +03:00
ensure sessions are never undefined
This commit is contained in:
parent
422eb18f1b
commit
5426f1db1d
@ -15,6 +15,7 @@
|
||||
const { activity, project, statuses, sessions, head } = data;
|
||||
|
||||
const recentSessions = derived(sessions, (sessions) => {
|
||||
sessions ||= [];
|
||||
const lastFourDaysOfSessions = sessions.filter(
|
||||
(session) => session.meta.startTimestampMs >= getTime(subDays(new Date(), 4))
|
||||
);
|
||||
|
Loading…
Reference in New Issue
Block a user