Only return tasks when calendar is defined
This commit is contained in:
parent
683eb47a8f
commit
9efc82c9ed
1 changed files with 2 additions and 0 deletions
|
@ -44,7 +44,9 @@ const getters = {
|
|||
*/
|
||||
getTasksByCalendarId: (state, getters, rootState) => (calendarId) => {
|
||||
var calendar = getters.getCalendarById(calendarId)
|
||||
if (calendar) {
|
||||
return Object.values(calendar.tasks)
|
||||
}
|
||||
},
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue