191 lines
9.6 KiB
TypeScript
191 lines
9.6 KiB
TypeScript
/* Metro module 6902; source: lib/guild/subscribeGuildMembers.tsx; dependencies: [29, 6, 7, 15, 17, 18, 31, 33, 22, 6903, 628, 1216, 2] */
|
|
function _fun54904(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#54904, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7080:6, offset: 0x01370aa8, size: 287 bytes, params: 8, frame: 19
|
|
let env0_0 = require;
|
|
const env0_3 = ['forwardedRef'];
|
|
const Object = global.Object;
|
|
Object.defineProperty(exports, '__esModule', {value: true});
|
|
const env0_4 = importDefault(29) /* metro dependency 29 */;
|
|
const env0_5 = importDefault(6) /* metro dependency 6 */;
|
|
const env0_6 = importDefault(7) /* metro dependency 7 */;
|
|
const env0_7 = importDefault(15) /* metro dependency 15 */;
|
|
const env0_8 = importDefault(17) /* metro dependency 17 */;
|
|
const env0_9 = importDefault(18) /* metro dependency 18 */;
|
|
const env0_10 = importAll(31) /* metro dependency 31 */;
|
|
const env0_11 = (require(33) /* metro dependency 33 */).jsx;
|
|
(require(2) /* metro dependency 2 */).fileFinishedImporting('lib/guild/subscribeGuildMembers.tsx');
|
|
exports.default = function(a0) {
|
|
var env0_0 = a0;
|
|
return _fun54909;
|
|
};
|
|
exports.MAX_GUILD_MEMBER_SUBSCRIPTIONS = 50;
|
|
exports.useSubscribeGuildMembers = useSubscribeGuildMembers;
|
|
}
|
|
|
|
function _isNativeReflectConstruct_54905() { // fn#54905, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7080:205, offset: 0x01370bc7, size: 94 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_54905_isNativeReflectConstruct = function() {
|
|
return !!result;
|
|
})();
|
|
}
|
|
|
|
function subscribeGuildMembers(a0) { // fn#54908, offset: 0x01370c25, size: 16 bytes, params: 2, frame: 2
|
|
const env0_0 = a0;
|
|
return _fun54909;
|
|
}
|
|
|
|
function useSubscribeGuildMembers(a0, a1) { // fn#54920, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7080:1859, offset: 0x01370fd4, size: 55 bytes, params: 3, frame: 15
|
|
const env0_0 = a0;
|
|
const env0_1 = a1;
|
|
env0_10.useEffect(_fun54921, [a0, a1]);
|
|
}
|
|
|
|
function _fun54909(a0) { // fn#54909, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7080:529, offset: 0x01370c35, size: 152 bytes, params: 2, frame: 17
|
|
const env0_0 = a0;
|
|
value = 'SubscribeGuildMembersContainer(' + (a0.displayName ?? a0.name ?? 'Component') + ')';
|
|
const binding = env1_10;
|
|
const Component = binding.Component;
|
|
_fun54910(Component).displayName = value;
|
|
const value4 = binding.forwardRef(_fun54919);
|
|
value4.displayName = 'ForwardRef(' + value + ')';
|
|
return value4;
|
|
}
|
|
|
|
function _fun54921() { // fn#54921, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7080:1911, offset: 0x0137100b, size: 57 bytes, params: 1, frame: 14
|
|
var environment;
|
|
let value = environment.__proto__;
|
|
value = importDefault(22) /* metro dependency 22 */;
|
|
value.forEach(env0_0, _fun54922);
|
|
return _fun54923;
|
|
}
|
|
|
|
function _fun54910(a0) { // fn#54910, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7080:681, offset: 0x01370ccd, size: 114 bytes, params: 2, frame: 16
|
|
const closure = WrappedComponent_54911;
|
|
env2_9(closure, a0);
|
|
return env2_6(closure, [{key: 'componentDidUpdate', value: value_54913}, {key: 'componentWillUnmount',
|
|
value: value_54916}, {key: 'render', value: value_54918}]);
|
|
}
|
|
|
|
function _fun54919(a0, a1) { // fn#54919, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7080:1714, offset: 0x01370fa4, size: 48 bytes, params: 3, frame: 14
|
|
return ((Component) => <Component {...a0} {...{['forwardedRef']: a1}} />)(env0_1);
|
|
}
|
|
|
|
function _fun54922(a0, a1) { // fn#54922, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7080:1935, offset: 0x01371044, size: 150 bytes, params: 3, frame: 17
|
|
var defaultImport;
|
|
var captureMessage;
|
|
var value4;
|
|
const value = environment.__proto__.__proto__;
|
|
if (!env2_12 && a0.length > 50) {
|
|
defaultImport = importDefault(1216) /* metro dependency 1216: SentryUtilsNative */;
|
|
captureMessage = defaultImport.captureMessage;
|
|
value4 = environment.__proto__;
|
|
Reflect.apply(captureMessage, defaultImport, ['SubscribeGuildMembers called with more than 50 userIds.',
|
|
{extra: {count: a0.length, guildId: a1, reason: require}}]);
|
|
}
|
|
(require(6903) /* metro dependency 6903: GuildSubscriptionsActionCreators */).subscribeMembers(a1, a0);
|
|
}
|
|
|
|
function _fun54923() { // fn#54923, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7080:2127, offset: 0x013710da, size: 52 bytes, params: 1, frame: 14
|
|
var environment;
|
|
let value = environment.__proto__.__proto__;
|
|
value = importDefault(22) /* metro dependency 22 */;
|
|
value.forEach(env1_0, _fun54924);
|
|
}
|
|
|
|
function WrappedComponent_54911(a0) { // fn#54911, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7080:693, offset: 0x01370d3f, size: 171 bytes, params: 2, frame: 21
|
|
var environment;
|
|
const value = environment.__proto__.__proto__.__proto__;
|
|
env3_5(this, WrappedComponent_54911);
|
|
const items2 = [a0];
|
|
const value3 = env3_8(WrappedComponent_54911);
|
|
const value6 = env3_7(this, _isNativeReflectConstruct_54905() ? global.Reflect.construct(value3, items2,
|
|
env3_8(this).constructor) : value3.apply(this, items2));
|
|
const value8 = env2_0(a0);
|
|
(importDefault(22) /* metro dependency 22 */).forEach(value8, _fun54912);
|
|
value6._subscriptions = value8;
|
|
return value6;
|
|
}
|
|
|
|
function value_54913(a0) { // fn#54913, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7080:1092, offset: 0x01370e17, size: 219 bytes, params: 2, frame: 19
|
|
var environment;
|
|
var r5;
|
|
var value2;
|
|
var value3;
|
|
var value4;
|
|
var defaultImport2;
|
|
var defaultImport3;
|
|
const value = environment.__proto__.__proto__.__proto__;
|
|
if (!(importDefault(628) /* metro dependency 628: shallowEqual */)(this.props, a0)) {
|
|
value2 = environment.__proto__.__proto__;
|
|
value3 = env2_0(this.props);
|
|
value4 = this._subscriptions != null;
|
|
if (value4) {
|
|
defaultImport2 = importDefault(22) /* metro dependency 22 */;
|
|
r5 = defaultImport2.isEqual(this._subscriptions, value3);
|
|
} else {
|
|
r5 = value4;
|
|
}
|
|
if (!r5) {
|
|
if (this._subscriptions != null) {
|
|
defaultImport3 = importDefault(22) /* metro dependency 22 */;
|
|
defaultImport3.forEach(this._subscriptions, _fun54914);
|
|
}
|
|
(importDefault(22) /* metro dependency 22 */).forEach(value3, _fun54915);
|
|
this._subscriptions = value3;
|
|
}
|
|
}
|
|
}
|
|
|
|
function value_54916() { // fn#54916, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7080:1443, offset: 0x01370f1f, size: 68 bytes, params: 1, frame: 13
|
|
var environment;
|
|
var value;
|
|
if (this._subscriptions != null) {
|
|
value = environment.__proto__.__proto__.__proto__;
|
|
value = importDefault(22) /* metro dependency 22 */;
|
|
value.forEach(this._subscriptions, _fun54917);
|
|
}
|
|
}
|
|
|
|
function value_54918() { // fn#54918, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7080:1581, offset: 0x01370f63, size: 65 bytes, params: 1, frame: 15
|
|
const props = this.props;
|
|
return ((Component) => <Component ref={props.forwardedRef} {...env3_4(props, env3_3)} />)(env1_0);
|
|
}
|
|
|
|
function _fun54924(a0, a1) { // fn#54924, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7080:2151, offset: 0x0137110e, size: 45 bytes, params: 3, frame: 13
|
|
const value = environment.__proto__.__proto__.__proto__;
|
|
return (require(6903) /* metro dependency 6903: GuildSubscriptionsActionCreators */).unsubscribeMembers(a1, a0);
|
|
}
|
|
|
|
function _fun54912(a0, a1) { // fn#54912, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7080:951, offset: 0x01370dea, size: 45 bytes, params: 3, frame: 13
|
|
const value = environment.__proto__.__proto__.__proto__.__proto__;
|
|
return (require(6903) /* metro dependency 6903: GuildSubscriptionsActionCreators */).subscribeMembers(a1, a0);
|
|
}
|
|
|
|
function _fun54914(a0, a1) { // fn#54914, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7080:1284, offset: 0x01370ef2, size: 45 bytes, params: 3, frame: 13
|
|
const value = environment.__proto__.__proto__.__proto__.__proto__;
|
|
return (require(6903) /* metro dependency 6903: GuildSubscriptionsActionCreators */).unsubscribeMembers(a1, a0);
|
|
}
|
|
|