Files
discord-decomp/sources/modules/video-qoe/integrations/MuxIntegration.tsx
T
2026-07-27 16:20:00 +03:00

69 lines
3.3 KiB
TypeScript

/* Metro module 13609; source: modules/video-qoe/integrations/MuxIntegration.tsx; dependencies: [6, 7, 2] */
function _fun103494(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#103494, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13799:6, offset: 0x0226b5f0, size: 126 bytes, params: 8, frame: 18
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
const env0_0 = importDefault(6) /* metro dependency 6 */;
const env0_1 = importDefault(7) /* metro dependency 7 */;
const value = _fun103495();
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/video-qoe/integrations/MuxIntegration.tsx');
exports.MuxIntegration = value;
}
function _fun103495() { // fn#103495, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13799:118, offset: 0x0226b66e, size: 114 bytes, params: 1, frame: 16
return env0_1(MuxIntegration, null, [{key: 'mapDiscordToMuxMetadata', value: value_103497}, {key: 'getAppVersion',
value: function() {
return '5867';
}}, {key: 'getBuildChannel', value: function() {
var r2;
var r0;
var property;
var value2;
var value3;
var error;
var value = undefined;
try {
property = global.window;
property = property.GLOBAL_ENV;
value2 = property == null;
if (value2) {
r2 = value;
} else {
property = property.RELEASE_CHANNEL;
r2 = property;
}
value = r2 != null;
value3 = 'stable';
r0 = value ? r2 : value3;
} catch (error) {
return 'stable';
}
return r0;
}}]);
}
function value_103497(a0, a1) { // fn#103497, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:13799:233, offset: 0x0226b6e0, size: 330 bytes, params: 3, frame: 15
const object2 = {'env_key': '1qd16mdmdjasipqg3irobln4u', 'session_id': null, 'player_name': 'discord',
'player_version': '1.0.0'};
object2.session_id = a1;
object2.video_id = a0.contentMetadata.contentId;
object2.video_title = a0.contentMetadata.title;
object2.video_duration = a0.contentMetadata.durationMs ?? (a0.contentMetadata.durationSec != null ? 1000 * a0.contentMetadata.durationSec : undefined);
object2.video_content_type = a0.contentMetadata.contentType;
object2.video_series = a0.contentMetadata.questId;
object2.video_producer = a0.contentMetadata.gameId;
object2.video_brand = a0.contentMetadata.gameName ?? 'Discord';
object2.video_cdn = 'Cloudflare';
object2.video_stream_type = a0.contentMetadata.videoStreamType;
object2.view_client_application_name = this.getBuildChannel();
object2.view_client_application_version = this.getAppVersion();
let userContext = a0.userContext;
value = undefined;
const userId = userContext == null ? value : userContext.userId;
object2.viewer_user_id = userId;
userContext = a0.userContext;
const userTier = userContext == null ? value : userContext.userTier;
object2.viewer_plan = userTier;
return object2;
}