Revert "fix(parties): actual 30 not 29"

This reverts commit bf0e640fa6.
This commit is contained in:
SabreCat
2023-08-16 16:56:01 -05:00
parent 694fe5a273
commit 63414a80fe
3 changed files with 4 additions and 4 deletions

View File

@@ -7,7 +7,7 @@ import {
} from '../../../../helpers/api-integration/v3'; } from '../../../../helpers/api-integration/v3';
const INVITES_LIMIT = 100; const INVITES_LIMIT = 100;
const PARTY_LIMIT_MEMBERS = 30; const PARTY_LIMIT_MEMBERS = 29;
const MAX_EMAIL_INVITES_BY_USER = 200; const MAX_EMAIL_INVITES_BY_USER = 200;
describe('Post /groups/:groupId/invite', () => { describe('Post /groups/:groupId/invite', () => {
@@ -571,7 +571,7 @@ describe('Post /groups/:groupId/invite', () => {
.to.eventually.be.rejected.and.eql({ .to.eventually.be.rejected.and.eql({
code: 400, code: 400,
error: 'BadRequest', error: 'BadRequest',
message: t('partyExceedsMembersLimit', { maxMembersParty: PARTY_LIMIT_MEMBERS }), message: t('partyExceedsMembersLimit', { maxMembersParty: PARTY_LIMIT_MEMBERS + 1 }),
}); });
}).timeout(10000); }).timeout(10000);
}); });

View File

@@ -27,7 +27,7 @@ export const SUPPORTED_SOCIAL_NETWORKS = [
export const GUILDS_PER_PAGE = 30; // number of guilds to return per page when using pagination export const GUILDS_PER_PAGE = 30; // number of guilds to return per page when using pagination
export const PARTY_LIMIT_MEMBERS = 30; export const PARTY_LIMIT_MEMBERS = 29;
export const MINIMUM_PASSWORD_LENGTH = 8; export const MINIMUM_PASSWORD_LENGTH = 8;
export const MAXIMUM_PASSWORD_LENGTH = 64; export const MAXIMUM_PASSWORD_LENGTH = 64;

View File

@@ -471,7 +471,7 @@ schema.statics.validateInvitations = async function getInvitationErr (invites, r
memberCount += totalInvites; memberCount += totalInvites;
if (memberCount > shared.constants.PARTY_LIMIT_MEMBERS) { if (memberCount > shared.constants.PARTY_LIMIT_MEMBERS) {
throw new BadRequest(res.t('partyExceedsMembersLimit', { maxMembersParty: shared.constants.PARTY_LIMIT_MEMBERS })); throw new BadRequest(res.t('partyExceedsMembersLimit', { maxMembersParty: shared.constants.PARTY_LIMIT_MEMBERS + 1 }));
} }
} }
}; };