decord/source/modules/activities/utils/getCanSendInvite.tsx

49 lines
1.6 KiB
TypeScript
Raw Normal View History

2026-08-25 06:04:03 +00:00
// Module ID: 12826
// Function ID: 12827
2026-07-20 16:05:17 +00:00
// Name: getCanSendInvite
2026-08-25 06:04:03 +00:00
// Dependencies: [676, 11313, 6037, 11314, 11315, 11316, 2]
2026-07-20 16:05:17 +00:00
// Exports: getCanSendInvite
2026-08-25 06:04:03 +00:00
// Module 12826 (getCanSendInvite)
2026-08-24 06:08:38 +00:00
import set from "set" /* 2 */;
2026-08-25 06:04:03 +00:00
import resultDefault from "result" /* 11313 */;
import getPartySize from "getPartySize" /* 11314 */;
import hasPartySize from "hasPartySize" /* 11315 */;
2026-08-24 06:08:38 +00:00
import ME from "ME" /* 676 */;
2026-07-23 10:11:24 +00:00
2026-07-29 08:29:29 +00:00
({ ActivityFlags: c3, ActivityActionTypes: c4 } = ME);
2026-08-24 06:08:38 +00:00
const result = set.fileFinishedImporting("modules/activities/utils/getCanSendInvite.tsx");
2026-07-20 16:05:17 +00:00
2026-07-29 08:29:29 +00:00
export const getCanSendInvite = function getCanSendInvite(findActivityResult, author, application, id1) {
2026-07-20 16:05:17 +00:00
if (author.author.id === id1) {
return false;
2026-07-29 08:29:29 +00:00
} else {
2026-08-24 06:08:38 +00:00
if (resultDefault(findActivityResult, author, application.id)) {
2026-07-29 08:29:29 +00:00
const activity = author.activity;
let type;
if (activity != null) {
type = activity.type;
}
if (type !== constants2.JOIN_REQUEST) {
return false;
2026-08-25 06:04:03 +00:00
} else if (tmp11(6037)(findActivityResult, constants.JOIN)) {
2026-08-24 06:08:38 +00:00
const partySize = getPartySize.getPartySize(findActivityResult);
const obj = getPartySize;
2026-07-29 08:29:29 +00:00
const tmp5 = require;
2026-08-24 06:08:38 +00:00
const hasPartySizeResult = hasPartySize.hasPartySize(partySize);
2026-07-29 08:29:29 +00:00
let isPartyFullResult = !hasPartySizeResult;
if (hasPartySizeResult) {
2026-08-25 06:04:03 +00:00
isPartyFullResult = tmp5(11316).isPartyFull(partySize);
const tmp5Result = tmp5(11316);
2026-07-29 08:29:29 +00:00
}
return !isPartyFullResult;
} else {
return false;
2026-07-20 16:05:17 +00:00
}
} else {
return false;
}
2026-07-29 08:29:29 +00:00
tmp11 = importDefault;
2026-07-20 16:05:17 +00:00
}
};