Files
discord-decomp/modules/game_console/trackVoiceCallTransfer.tsx
T
2026-11-01 12:12:55 +02:00

23 lines
898 B
TypeScript

// Metro module 9045 (f9046).
import ChannelStore from "../../stores/ChannelStore";
import RTCConnectionStore from "../../stores/RTCConnectionStore";
import SessionsStore from "../../stores/SessionsStore";
import { AnalyticEvents } from "../../Constants";
import AnalyticsUtils from "../../utils/AnalyticsUtils";
export default function trackVoiceCallTransfer(a0, a1, a2) {
const VOICE_CALL_TRANSFER = AnalyticEvents.VOICE_CALL_TRANSFER;
const r2 = a2 != null;
let source_platform = "discord_client";
if (r2) {
const sessionById = SessionsStore.getSessionById(a2);
source_platform = sessionById == null ? void 0 : sessionById.clientInfo.os;
}
AnalyticsUtils.track(VOICE_CALL_TRANSFER, {
source_platform,
guild_id: ChannelStore.getChannel(a0)?.guild_id,
channel_id: a0,
rtc_connection_id: RTCConnectionStore.getRTCConnectionId(),
target_platform: a1
});
};