Files
2026-07-28 01:06:53 +03:00

103 lines
5.2 KiB
TypeScript

/* Metro module 10018; source: modules/game_profile/navigateToGameAnnouncement.tsx; dependencies: [5, 1867, 661, 44, 6946, 8879, 1230, 2] */
import Module00005 from '../../by-id/module-00005.js'; /* Metro dependency 5 */
import GuildStore from '../../stores/GuildStore.tsx'; /* Metro dependency 1867 */
import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
import * as ConstantsModule from '../../Constants.tsx'; /* Metro dependency 661 */
function _fun78248(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#78248, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:10204:6, offset: 0x01e2261e, size: 187 bytes, params: 8, frame: 19
const env0_0 = require;
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
(FileImportTrackerModule).fileFinishedImporting('modules/game_profile/navigateToGameAnnouncement.tsx');
exports.default = function() {
return _navigateToGameAnnouncement.apply(this, arguments);
};
function _navigateToGameAnnouncement() { // fn#78249, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:10204:176, offset: 0x01e226d9, size: 50 bytes, params: 1, frame: 14
return Module00005(_fun78251).apply(this, arguments);
async function _fun78251({invite, guildId, channelId, messageId, analyticsLocationStack}) { // fn#78251, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:10204:253, offset: 0x01e2271f, size: 511 bytes, params: 2, frame: 28
var id;
var features;
var r7;
var r13;
var guild;
var Set;
var set;
var value14;
var transitionTo;
var value16;
if (false) {
return undefined;
}
value = undefined;
await value;
if (false) {
return undefined;
}
let binding = env2_1;
binding(env2_2[3])(analyticsLocationStack.length > 0, 'analyticsLocationStack must have at least one location');
const property = analyticsLocationStack[analyticsLocationStack.length - 1];
if (invite != null) {
guild = invite.guild;
id = guild == null ? value : guild.id;
Set = global.Set;
guild = invite.guild;
features = guild == null ? value : guild.features;
set = new Set();
r7 = id;
r13 = set;
} else {
r7 = guildId;
r13 = null;
}
if (r7 != null) {
var guild2 = env2_4.getGuild(r7);
if ((guild2 == null ? value : guild2.joinedAt) != null) {
binding = env2_0;
value14 = binding(env2_2[6]);
transitionTo = value14.transitionTo;
binding = env2_7;
Reflect.apply(transitionTo, value14, [binding.CHANNEL(r7, channelId, messageId),
{sourceLocationStack: analyticsLocationStack}]);
return value;
}
if (r13 == null) {
value16 = env2_0(env2_2[4]);
await value16.startLurking(r7, {}, {shouldNavigate: true, channelId: channelId, messageId: messageId,
joinSource: env2_6.GAME_PROFILE_ANNOUNCEMENTS}, analyticsLocationStack);
return value;
}
var has = r13.has;
var PREVIEW_ENABLED = env2_5.PREVIEW_ENABLED;
if (Reflect.apply(has, r13, [PREVIEW_ENABLED])) {
value16 = env2_0(env2_2[4]);
await value16.startLurking(r7, {}, {shouldNavigate: true, channelId: channelId, messageId: messageId,
joinSource: env2_6.GAME_PROFILE_ANNOUNCEMENTS}, analyticsLocationStack);
return value;
}
if (invite == null) {
binding = env2_0;
value14 = binding(env2_2[6]);
transitionTo = value14.transitionTo;
binding = env2_7;
Reflect.apply(transitionTo, value14, [binding.CHANNEL(r7, channelId, messageId),
{sourceLocationStack: analyticsLocationStack}]);
return value;
}
var value11 = env2_1(env2_2[5]);
await value11.acceptInvite({inviteKey: invite.code, context: {location: property}, skipOnboarding: true});
if (false) {
return undefined;
}
value14 = env2_0(env2_2[6]);
value14.transitionTo(env2_7.CHANNEL(r7, channelId, messageId), {sourceLocationStack: analyticsLocationStack});
}
return value;
}
}
}
global.__d(_fun78248, 10018, [5, 1867, 661, 44, 6946, 8879, 1230,
2]) /* metro module 10018, dependencies: [5, 1867, 661, 44, 6946, 8879, 1230, 2] */;