Files
discord-decomp/sources/modules/headless_tasks/android/SelectVoiceChannel.tsx
T
2026-07-27 16:20:00 +03:00

51 lines
2.8 KiB
TypeScript

/* Metro module 16267; source: modules/headless_tasks/android/SelectVoiceChannel.tsx; dependencies: [1379, 4294, 16260, 4796, 7709, 4601, 2] */
function _fun125732(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#125732, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16475:6, offset: 0x025e2168, size: 102 bytes, params: 8, frame: 14
const env0_0 = require;
const channelStore = importDefault(1379) /* metro dependency 1379: ChannelStore */;
const rtcConnectionStore = importDefault(4294) /* metro dependency 4294: RTCConnectionStore */;
module.exports = function({channelId, connectToVoice}) {
var Promise = global.Promise;
var value = Object.create(Promise.prototype, {constructor: {value: Promise}});
var value2 = new Promise(_fun125734);
return value2 instanceof Object ? value2 : value;
};
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/headless_tasks/android/SelectVoiceChannel.tsx');
}
function exports_125733({channelId, connectToVoice}) { // fn#125733, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16475:77, offset: 0x025e21ce, size: 63 bytes, params: 2, frame: 11
const Promise = global.Promise;
const value = Object.create(Promise.prototype, {constructor: {value: Promise}});
const promise = new Promise(_fun125734);
return promise instanceof Object ? promise : value;
}
function _fun125734(a0) { // fn#125734, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16475:124, offset: 0x025e220d, size: 54 bytes, params: 2, frame: 12
var environment;
const env0_0 = a0;
const value = environment.__proto__;
(importDefault(16260) /* metro dependency 16260: HeadlessTaskUtils */).awaitStorage(_fun125735);
}
function _fun125735() { // fn#125735, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:16475:150, offset: 0x025e2243, size: 189 bytes, params: 1, frame: 13
var value2;
var defaultImport;
var moduleValue;
let value = environment.__proto__;
if (connectToVoice) {
value2 = environment.__proto__.__proto__;
defaultImport = importDefault(4796) /* metro dependency 4796: SelectedChannelActionCreators */;
defaultImport.selectVoiceChannel(channelId);
}
if (RTCConnectionStore.getChannelId() === channelId) {
value = ChannelStore.getChannel(channelId);
if (value != null) {
(require(7709) /* metro dependency 7709: PrivateChannelCallUtils */).navigateToVoiceChannel(value);
}
} else {
moduleValue = require(4601) /* metro dependency 4601: transitionToChannel */;
moduleValue.transitionToChannel(channelId);
}
env0_0(true);
}