Add comment to unreadable code block

This commit is contained in:
Ramon Wenger 2019-07-25 09:52:26 +02:00
parent 185cd4a81e
commit 0c2cc090e2
1 changed files with 3 additions and 0 deletions

View File

@ -34,8 +34,11 @@
return this.me.selectedClass || {id: 'U2Nob29sQ2xhc3NOb2RlOjE='}; // todo: remove after merge with select class feature
},
hidden() {
// is this content block / objective group user created?
return (this.isContentBlock ? this.block.userCreated : !!this.block.owner)
// if so, is visibility not explicitly set for this school class?
? this.block.visibleFor.findIndex(el => el.id === this.schoolClass.id) === -1
// otherwise, is it explicitly hidden for this school class?
: this.block.hiddenFor.findIndex(el => el.id === this.schoolClass.id) > -1;
}
},