Revert invite gather to requiring membership of team 949 (Invite Gathers)

This commit is contained in:
xGolden 2021-04-12 21:49:02 -04:00
parent 8d9a927d80
commit 10647e41e3
4 changed files with 5 additions and 6 deletions

1
.gitignore vendored
View file

@ -11,3 +11,4 @@ public/vendor.js
public/vendor.js.map public/vendor.js.map
db/data db/data
.env .env
.idea/

View file

@ -39,10 +39,10 @@ const GATHER_CONFIGS = [
type: "invitational", type: "invitational",
icon: "/inviteGather.png", icon: "/inviteGather.png",
name: "Invitational Gather", name: "Invitational Gather",
description: "You must be on a nsl team to join", description: "Join on ensl.org/teams/949",
// Grant invite if on any nsl team // Grant invite if on a particular nsl team
membershipTest: function (user) { membershipTest: function (user) {
return user.team !== undefined; return InvitationalGather.list.some(m => m.id === user.id);
}, },
serverMembershipTest: function (server) { serverMembershipTest: function (server) {
return server.name.toLowerCase().indexOf("promod") === -1; return server.name.toLowerCase().indexOf("promod") === -1;

View file

@ -4,7 +4,7 @@ const winston = require("winston");
const env = process.env.NODE_ENV || "development"; const env = process.env.NODE_ENV || "development";
const client = require("../ensl/client")(); const client = require("../ensl/client")();
const REFRESH_INTERVAL = 1000 * 60; // Check every minute const REFRESH_INTERVAL = 1000 * 60; // Check every minute
const invitationalTeamId = env === "production" ? 949 : 866; const invitationalTeamId = 949;
function InvitationalGather () { function InvitationalGather () {

View file

@ -21,5 +21,3 @@ module.exports = {
getRandomUser, getRandomUser,
getFixedUser getFixedUser
}; };