Skip to content

Commit

Permalink
fix: tests
Browse files Browse the repository at this point in the history
  • Loading branch information
barisusakli committed Jul 29, 2020
1 parent bbc7737 commit 9df871b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/groups/membership.js
Expand Up @@ -24,7 +24,7 @@ module.exports = function (Groups) {
};

Groups.isMember = async function (uid, groupName) {
if (!uid || !(parseInt(uid, 10) > 0) || !groupName) {
if (!uid || parseInt(uid, 10) <= 0 || !groupName) {
return false;
}

Expand Down Expand Up @@ -65,7 +65,7 @@ module.exports = function (Groups) {
};

Groups.isMemberOfGroups = async function (uid, groups) {
if (!uid || !(parseInt(uid, 10) > 0) || !groups.length) {
if (!uid || parseInt(uid, 10) <= 0 || !groups.length) {
return groups.map(groupName => groupName === 'guests');
}
const cachedData = {};
Expand Down

0 comments on commit 9df871b

Please sign in to comment.