// Metro module 8213 (f8214). import ChannelStore from "../../../stores/ChannelStore"; import { EntityChannelTypes, GuildScheduledEventEntityTypes } from "../GuildScheduledEventsConstants"; export function getChannelFromEvent(a0) { const { entity_type, channel_id } = a0; const r0 = entity_type in EntityChannelTypes && channel_id != null; let r7 = void 0; if (r0) { let r11 = ChannelStore.getChannel(a0.channel_id); if (r11 == null) { r11 = void 0; } r7 = r11; } return r7; } export function getLocationFromEvent({ entity_type, entity_metadata }) { return entity_type === GuildScheduledEventEntityTypes.EXTERNAL && entity_metadata != null && "location" in entity_metadata ? entity_metadata.location : null; } export function getLocationFromEventData({ entityType, entityMetadata }) { return entityType === GuildScheduledEventEntityTypes.EXTERNAL && entityMetadata != null && "location" in entityMetadata ? entityMetadata.location : null; } export function getChannelTypeFromEntity(a0) { return a0 !== GuildScheduledEventEntityTypes.VOICE ? a0 === GuildScheduledEventEntityTypes.STAGE_INSTANCE ? EntityChannelTypes[a0] : void 0 : EntityChannelTypes[a0]; }