109 lines
4.6 KiB
TypeScript
109 lines
4.6 KiB
TypeScript
/* Metro module 15385; source: modules/quests/UnenrolledActivityQuestStore.tsx; dependencies: [6, 7, 15, 17, 18, 21, 566, 694, 2] */
|
|
function _fun117616(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#117616, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15582:6, offset: 0x024bae13, size: 350 bytes, params: 8, frame: 19
|
|
const Object = global.Object;
|
|
Object.defineProperty(exports, '__esModule', {value: true});
|
|
const env0_2 = importDefault(6) /* metro dependency 6 */;
|
|
const env0_3 = importDefault(7) /* metro dependency 7 */;
|
|
const env0_4 = importDefault(15) /* metro dependency 15 */;
|
|
const env0_5 = importDefault(17) /* metro dependency 17 */;
|
|
const env0_6 = importDefault(18) /* metro dependency 18 */;
|
|
let Set = global.Set;
|
|
Object.create(Set.prototype, {constructor: {value: Set}});
|
|
new Set();
|
|
Set = global.Set;
|
|
let set = new Set();
|
|
const PersistedStore = (importDefault(566) /* metro dependency 566: flux */).PersistedStore;
|
|
set = _fun117620(PersistedStore);
|
|
set.displayName = 'UnenrolledActivityQuestStore';
|
|
set.persistKey = 'UnenrolledActivityQuestStore';
|
|
set = new set(importDefault(694) /* metro dependency 694: Dispatcher */,
|
|
{UNENROLLED_ACTIVITY_QUEST_DISMISS: UNENROLLED_ACTIVITY_QUEST_DISMISS,
|
|
UNENROLLED_ACTIVITY_QUEST_AUTO_ENROLL: function(a0) {
|
|
env0_8 = a0.autoEnroll;
|
|
return true;
|
|
}});
|
|
(require(2) /* metro dependency 2 */).fileFinishedImporting('modules/quests/UnenrolledActivityQuestStore.tsx');
|
|
exports.default = set;
|
|
}
|
|
|
|
function _isNativeReflectConstruct_117617() { // fn#117617, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15582:148, offset: 0x024baf71, 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_117617_isNativeReflectConstruct = function() {
|
|
return !!result;
|
|
})();
|
|
}
|
|
|
|
function _fun117620(a0) { // fn#117620, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15582:412, offset: 0x024bafd3, size: 149 bytes, params: 2, frame: 16
|
|
const closure = UnenrolledActivityQuestStore;
|
|
env0_6(closure, a0);
|
|
return env0_3(closure, [{key: 'initialize', value: function(a0) {
|
|
var r2;
|
|
var r3;
|
|
var property = global.Set;
|
|
var value = undefined;
|
|
r2 = a0 == null ? value : a0.dismissedQuestIds;
|
|
r2 = r2 ?? [];
|
|
var value3 = new property();
|
|
r3 = a0 == null ? value : a0.autoEnroll;
|
|
env1_8 = r3 != null && r3;
|
|
return value;
|
|
}}, {key: 'getState', value: value_117623}, {key: 'isDismissed', value: value_117624}, {key: 'getDismissedQuestIds',
|
|
value: value_117625}]);
|
|
}
|
|
|
|
function UNENROLLED_ACTIVITY_QUEST_DISMISS({questId}) { // fn#117626, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15582:1280, offset: 0x024bb0f1, size: 189 bytes, params: 2, frame: 15
|
|
var value2;
|
|
var value3;
|
|
var slice;
|
|
var Math;
|
|
var value4;
|
|
var Set;
|
|
var value5;
|
|
var set;
|
|
if (env0_7.size >= 20) {
|
|
value2 = global.Array.from(env0_7);
|
|
value3 = value2.sort((importDefault(21) /* metro dependency 21: SnowflakeUtils */).compare);
|
|
slice = value3.slice;
|
|
Math = global.Math;
|
|
value4 = Reflect.apply(slice, value3, [Math.floor(10)]);
|
|
Set = global.Set;
|
|
value5 = value4.map(function(a0) {
|
|
return a0.toString();
|
|
});
|
|
set = new Set();
|
|
}
|
|
env0_7.add(questId);
|
|
return true;
|
|
}
|
|
|
|
function value_117623() { // fn#117623, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:15582:930, offset: 0x024bb0cb, size: 38 bytes, params: 1, frame: 15
|
|
const binding = env1_7;
|
|
const items2 = [];
|
|
arraySpread(items2, binding, 0, undefined);
|
|
return {dismissedQuestIds: items2, autoEnroll: env1_8};
|
|
}
|
|
|