decord/alpha/source/modules/guests/GuestUtils.tsx
github-actions 52331fb8ae chore: update source for alpha 349.2
Skipped 1 file(s) >100MB (GitHub limit): source/__polyfill/05xxx/module_5051.js (118.4 MB)
2026-09-30 07:29:52 +00:00

42 lines
1.2 KiB
TypeScript

// Module ID: 11058
// Function ID: 11059
// Name: GuestUtils
// Dependencies: [4485, 1385, 8035, 2]
// Module 11058 (GuestUtils)
import FlagUtils from "FlagUtils" /* 1385 */;
import GuildMemberConstants from "GuildMemberConstants" /* 4485 */;
import size from "module_2" /* 2 */;
const GuildMemberFlags = GuildMemberConstants.GuildMemberFlags;
const result = size.fileFinishedImporting("modules/guests/GuestUtils.tsx");
export default {
canAcceptInvite(items, guild) {
[obj] = items;
guild = guild.guild;
let tmp = null == guild;
if (!tmp) {
const selfMember = obj.getSelfMember(guild.id);
let num;
if (selfMember != null) {
num = selfMember.flags;
}
if (num == null) {
num = 0;
}
const hasFlagResult = FlagUtils.hasFlag(num, GuildMemberFlags.IS_GUEST);
let hasFlagResult1 = !hasFlagResult;
if (hasFlagResult) {
let num2 = guild.flags;
if (num2 == null) {
num2 = 0;
}
hasFlagResult1 = tmp2(1385).hasFlag(num2, tmp2(8035).GuildInviteFlags.IS_GUEST_INVITE);
const tmp2Result = tmp2(1385);
}
tmp = hasFlagResult1;
}
return tmp;
}
};