Skip to content

Commit

Permalink
small fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Jonas Heinrich committed Oct 14, 2023
1 parent 4d23963 commit 56467f0
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/components/Editor/Invitees/InviteesList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
:is-read-only="isReadOnly || isSharedWithMe"
:organizer="calendarObjectInstance.organizer" />
<InviteesListItem v-for="invitee in inviteesWithoutOrganizer"
v-if="noGroupOrNoneEmpty(invitee)"

Check failure on line 35 in src/components/Editor/Invitees/InviteesList.vue

View workflow job for this annotation

GitHub Actions / eslint

The 'inviteesWithoutOrganizer' variable inside 'v-for' directive should be replaced with a computed property that returns filtered array instead. You should not mix 'v-for' with 'v-if'
:key="invitee.email"
:attendee="invitee"
:is-read-only="isReadOnly || isSharedWithMe"
Expand Down Expand Up @@ -129,12 +130,6 @@ export default {
},
invitees() {
return this.calendarObjectInstance.attendees.filter(attendee => {
// Hide empty groups
// if (attendee.attendeeProperty.userType === 'GROUP' && attendee.members) {
// if (attendee.members.length === 0) {
// return false
// }
// }
return !['RESOURCE', 'ROOM'].includes(attendee.attendeeProperty.userType)
})
},
Expand Down Expand Up @@ -304,6 +299,11 @@ export default {
this.creatingTalkRoom = false
}
},
noGroupOrNoneEmpty(attendee) {
return attendee.attendeeProperty.userType !== 'GROUP'
|| (attendee.attendeeProperty.userType === 'GROUP' && attendee.members
&& attendee.members.length !== 0)
}

Check warning on line 306 in src/components/Editor/Invitees/InviteesList.vue

View workflow job for this annotation

GitHub Actions / eslint

Missing trailing comma
},
}
</script>
Expand Down

0 comments on commit 56467f0

Please sign in to comment.