mirror of
https://github.com/wekan/wekan.git
synced 2025-12-29 21:58:49 +01:00
Export Wekan now server-based with proper auth
This commit is contained in:
parent
efe7c21d57
commit
d08e1cc45b
6 changed files with 42 additions and 26 deletions
|
|
@ -80,15 +80,15 @@ Boards.attachSchema(new SimpleSchema({
|
|||
|
||||
Boards.helpers({
|
||||
/**
|
||||
* Is current logged-in user authorized to view this board?
|
||||
* Is supplied user authorized to view this board?
|
||||
*/
|
||||
isVisibleByUser() {
|
||||
isVisibleBy(user) {
|
||||
if(this.isPublic()) {
|
||||
// public boards are visible to everyone
|
||||
return true;
|
||||
} else {
|
||||
// otherwise you have to be logged-in and active member
|
||||
return this.isActiveMember(Meteor.userId());
|
||||
return this.isActiveMember(user._id);
|
||||
}
|
||||
},
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue