Files
discord-decomp/sources/stores/GeoRestrictedGuildStore.tsx
T
2026-07-28 01:06:53 +03:00

95 lines
5.1 KiB
TypeScript

/* Metro module 12592; source: stores/GeoRestrictedGuildStore.tsx; dependencies: [6, 7, 15, 17, 18, 566, 694, 2] */
import ClassCallCheck from '../by-id/module-00006-ClassCallCheck.js'; /* Metro dependency 6 */
import CreateClass from '../by-id/module-00007-CreateClass.js'; /* Metro dependency 7 */
import PossibleConstructorReturn from '../by-id/module-00015-PossibleConstructorReturn.js'; /* Metro dependency 15 */
import Module00017 from '../by-id/module-00017.js'; /* Metro dependency 17 */
import Inherits from '../by-id/module-00018-Inherits.js'; /* Metro dependency 18 */
import Flux from '../external/discord_common/js/packages/flux/index.tsx'; /* Metro dependency 566 */
import * as FileImportTrackerModule from '../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
function _fun96494(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#96494, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12782:6, offset: 0x0215f954, size: 297 bytes, params: 8, frame: 18
const Object = global.Object;
Object.defineProperty(exports, '__esModule', {value: true});
let env0_5 = [];
const Store = (Flux).Store;
let value = _fun96498(Store);
value.displayName = 'GeoRestrictedGuildStore';
value = new value(importDefault(694) /* metro dependency 694: Dispatcher */, {CONNECTION_OPEN: function(a0) {
env0_5 = a0.geoRestrictedGuilds;
}, GUILD_DELETE: GUILD_DELETE_96502, GUILD_GEO_RESTRICTED: GUILD_GEO_RESTRICTED_96505});
(FileImportTrackerModule).fileFinishedImporting('stores/GeoRestrictedGuildStore.tsx');
exports.default = value;
function _isNativeReflectConstruct_96495() { // fn#96495, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12782:149, offset: 0x0215fa7d, size: 98 bytes, params: 1, frame: 18
var Boolean;
var prototype;
var valueOf;
var call;
var Reflect;
var construct;
var closure;
var value;
var error;
try {
Boolean = global.Boolean;
prototype = Boolean.prototype;
valueOf = prototype.valueOf;
call = valueOf.call;
Reflect = global.Reflect;
construct = Reflect.construct;
Boolean = global.Boolean;
closure = function() {
};
value = Reflect.apply(construct, Reflect, [Boolean, [], closure]);
value = Reflect.apply(call, valueOf, [value]);
var result = !value;
} catch (error) {
}
return (_isNativeReflectConstruct_96495_isNativeReflectConstruct = function() {
return !!result;
})();
}
function _fun96498(a0) { // fn#96498, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12782:357, offset: 0x0215fadf, size: 74 bytes, params: 2, frame: 15
const GeoRestrictedGuildStore2 = GeoRestrictedGuildStore;
Inherits(GeoRestrictedGuildStore2, a0);
return CreateClass(GeoRestrictedGuildStore2, [{key: 'getGeoRestrictedGuilds', value: value_96500}]);
function GeoRestrictedGuildStore() { // fn#96499, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12782:369, offset: 0x00c7a0d6, size: 113 bytes, params: 1, frame: 20
const value = environment.__proto__;
env1_0(this, GeoRestrictedGuildStore);
const value3 = env1_3(GeoRestrictedGuildStore);
return env1_2(this, _isNativeReflectConstruct_96495() ? global.Reflect.construct(value3, arguments,
env1_3(this).constructor) : value3.apply(this, arguments));
}
function value_96500() { // fn#96500, offset: 0x00e40571, size: 9 bytes, params: 1, frame: 1
return env1_5;
}
}
function GUILD_DELETE_96502({guild}) { // fn#96502, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12782:902, offset: 0x0215fb3d, size: 82 bytes, params: 2, frame: 13
if (env0_5.findIndex(function({id}) {
return id === guild.id;
}) === -1) {
return false;
}
env0_5 = env0_5.filter(function({id}) {
return id !== guild.id;
});
}
function GUILD_GEO_RESTRICTED_96505(a0) { // fn#96505, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12782:1038, offset: 0x0215fb8f, size: 92 bytes, params: 2, frame: 14
const env0_0 = a0;
env0_5.filter(_fun96506).push({id: a0.guildId, name: a0.name, icon: a0.icon, unavailable: true,
geo_restricted: true});
function _fun96506({id}) { // fn#96506, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:12782:1089, offset: 0x0215fbeb, size: 26 bytes, params: 2, frame: 2
return id !== env0_0.guildId;
}
}
}
global.__d(_fun96494, 12592, [6, 7, 15, 17, 18, 566, 694,
2]) /* metro module 12592, dependencies: [6, 7, 15, 17, 18, 566, 694, 2] */;