/* Metro module 10545; source: utils/InviteErrorUtils.tsx; dependencies: [1878, 661, 3802, 1244, 1948, 2] */ import UserStore from '../stores/UserStore.tsx'; /* Metro dependency 1878 */ import * as FileImportTrackerModule from '../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */ import * as ConstantsModule from '../Constants.tsx'; /* Metro dependency 661 */ import * as IndexNativeModule from '../intl/index.native.tsx'; /* Metro dependency 1244 */ function _fun81318(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#81318, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:10731:6, offset: 0x01eca1d8, size: 183 bytes, params: 8, frame: 19 const env0_0 = require; const Object = global.Object; Object.defineProperty(exports, '__esModule', {value: true}); (FileImportTrackerModule).fileFinishedImporting('utils/InviteErrorUtils.tsx'); exports.getDescriptiveInviteError = getDescriptiveInviteError; exports.getInviteError = getInviteError; function getDescriptiveInviteError(a0) { // fn#81319, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:10731:288, offset: 0x01eca28f, size: 618 bytes, params: 2, frame: 19 var object; const intl = (IndexNativeModule).intl; const t = (IndexNativeModule).t; var currentUser; var value3; var defaultImport; const TOO_MANY_USER_GUILDS = AbortCodes.TOO_MANY_USER_GUILDS; if (TOO_MANY_USER_GUILDS === a0) { currentUser = UserStore.getCurrentUser(); value3 = undefined; defaultImport = importDefault(3802) /* metro dependency 3802: PremiumUtils */; return {title: intl.formatToPlainString(t['ttJ/hj'], {quantity: defaultImport.canUseIncreasedGuildCap(currentUser) || (currentUser == null ? value3 : currentUser.isStaff()) ? MAX_USER_GUILDS_PREMIUM : MAX_USER_GUILDS}), description: intl.string(t.iLyuDO)}; } const GUILD_AT_CAPACITY = AbortCodes.GUILD_AT_CAPACITY; if (GUILD_AT_CAPACITY === a0) { object = {}; object.title = intl.string(t.ZZlox4); object.description = intl.string(t.ZUEGFn); return object; } const GUILD_JOIN_INVITE_LIMITED_ACCESS = AbortCodes.GUILD_JOIN_INVITE_LIMITED_ACCESS; if (GUILD_JOIN_INVITE_LIMITED_ACCESS === a0) { object = {}; object.title = intl.string(t.kJwpBW); object.description = intl.string(t.ZUEGFn); return object; } const USER_GUILD_JOIN_LARGE_GUILD_UNDERAGE_DISALLOWED = AbortCodes.USER_GUILD_JOIN_LARGE_GUILD_UNDERAGE_DISALLOWED; if (USER_GUILD_JOIN_LARGE_GUILD_UNDERAGE_DISALLOWED === a0) { object = {}; object.title = intl.string(t['u/xsK9']); object.description = intl.string(t.SxY4IW); return object; } return null; } function getInviteError(a0) { // fn#81320, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:10731:1059, offset: 0x01eca4f9, size: 495 bytes, params: 2, frame: 18 const intl = (IndexNativeModule).intl; const t = (IndexNativeModule).t; var format; var RXSeLl; var defaultImport; const TOO_MANY_USER_GUILDS = AbortCodes.TOO_MANY_USER_GUILDS; if (TOO_MANY_USER_GUILDS === a0) { return intl.string(t.iLyuDO); } const GUILD_AT_CAPACITY = AbortCodes.GUILD_AT_CAPACITY; if (GUILD_AT_CAPACITY === a0) { return intl.string(t.M6unNJ); } const INVALID_COUNTRY_CODE = AbortCodes.INVALID_COUNTRY_CODE; if (INVALID_COUNTRY_CODE === a0) { return intl.string(t.sRJGR1); } const INVALID_CANNOT_FRIEND_SELF = AbortCodes.INVALID_CANNOT_FRIEND_SELF; if (INVALID_CANNOT_FRIEND_SELF === a0) { return intl.string(t['mY2R+F']); } const INVITES_DISABLED = AbortCodes.INVITES_DISABLED; if (INVITES_DISABLED === a0) { format = intl.format; RXSeLl = t.RXSeLl; defaultImport = importDefault(1948) /* metro dependency 1948: HelpdeskUtils */; return Reflect.apply(format, intl, [RXSeLl, {articleLink: defaultImport.getArticleURL(HelpdeskArticles.INVITE_DISABLED)}]); } return intl.string(t.dDZRdy); } } global.__d(_fun81318, 10545, [1878, 661, 3802, 1244, 1948, 2]) /* metro module 10545, dependencies: [1878, 661, 3802, 1244, 1948, 2] */;