decord/source/modules/guild_onboarding/doGuildOnboardingHelpers.tsx

39 lines
1.2 KiB
TypeScript
Raw Normal View History

2026-08-05 07:35:12 +00:00
// Module ID: 5199
// Function ID: 5200
2026-07-20 16:05:17 +00:00
// Name: waitForOnboardingCompletion
2026-08-05 07:35:12 +00:00
// Dependencies: [1942, 3871, 1384, 5200, 2]
2026-07-20 16:05:17 +00:00
// Exports: waitForOnboardingCompletion
2026-08-05 07:35:12 +00:00
// Module 5199 (waitForOnboardingCompletion)
2026-07-29 08:29:29 +00:00
import trackCommunicationDisabled from "trackCommunicationDisabled";
2026-07-23 10:11:24 +00:00
import { GuildMemberFlags } from "GuildMemberFlags";
const require = arg1;
let result = require("hasFlag").fileFinishedImporting("modules/guild_onboarding/doGuildOnboardingHelpers.tsx");
2026-07-20 16:05:17 +00:00
export const waitForOnboardingCompletion = function waitForOnboardingCompletion(arg0) {
2026-07-23 10:11:24 +00:00
let closure_0 = arg0;
2026-07-20 16:05:17 +00:00
return new Promise((arg0) => {
2026-07-23 10:11:24 +00:00
let closure_0 = arg0;
const result = outer1_3.addConditionalChangeListener(() => {
const selfMember = outer2_3.getSelfMember(callback);
2026-07-29 08:29:29 +00:00
let num;
if (selfMember != null) {
num = selfMember.flags;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
if (num == null) {
num = 0;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
const hasFlagResult = callback(outer2_2[2]).hasFlag(num, outer2_4.COMPLETED_ONBOARDING);
let flag = !hasFlagResult;
if (hasFlagResult) {
2026-07-23 10:11:24 +00:00
outer2_1(outer2_2[3]).finishOnboarding(callback);
callback();
2026-07-20 16:05:17 +00:00
flag = false;
2026-07-23 10:11:24 +00:00
const obj2 = outer2_1(outer2_2[3]);
2026-07-20 16:05:17 +00:00
}
return flag;
});
});
};