55 lines
2.7 KiB
JavaScript
55 lines
2.7 KiB
JavaScript
/* Metro module 7451; source: unknown; dependencies: [] */
|
|
function _fun60112(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#60112, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7629:6, offset: 0x016fc363, size: 85 bytes, params: 8, frame: 16
|
|
const Object = global.Object;
|
|
Object.defineProperty(exports, '__esModule', {value: true});
|
|
exports.getNumberOfUrlSegments = function(a0) {
|
|
return a0.split(RegExp('\\\\?\\/', '')).filter(_fun60114).length;
|
|
};
|
|
exports.getSanitizedUrlString = getSanitizedUrlString_60115;
|
|
exports.parseUrl = parseUrl_60116;
|
|
exports.stripUrlQueryAndFragment = function(a0) {
|
|
return a0.split(RegExp('[?#]', ''), 1)[0];
|
|
};
|
|
function getNumberOfUrlSegments_60113(a0) { // fn#60113, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7629:104, offset: 0x016fc3b8, size: 51 bytes, params: 2, frame: 11
|
|
const value = a0.split(RegExp('\\\\?\\/', ''));
|
|
return value.filter(function(a0) {
|
|
return a0.length > 0 && a0 !== ',';
|
|
}).length;
|
|
}
|
|
|
|
}
|
|
|
|
function _fun60114(a0) { // fn#60114, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7629:171, offset: 0x00dd8da1, size: 27 bytes, params: 2, frame: 3
|
|
return a0.length > 0 && a0 !== ',';
|
|
}
|
|
|
|
function getSanitizedUrlString_60115({protocol, host, path}) { // fn#60115, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7629:245, offset: 0x016fc3eb, size: 171 bytes, params: 2, frame: 18
|
|
const value = '';
|
|
const r2 = protocol ? value + protocol + '://' : value;
|
|
let r1 = host && host.replace(RegExp('^.*@', ''), '[filtered]:[filtered]@').replace(RegExp('(:80)$', ''),
|
|
value).replace(RegExp('(:443)$', ''), value);
|
|
r1 = !r1 ? value : r1;
|
|
return value + r2 + r1 + path;
|
|
}
|
|
|
|
function parseUrl_60116(a0) { // fn#60116, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:7629:451, offset: 0x00d71d6d, size: 136 bytes, params: 2, frame: 14
|
|
var r3;
|
|
var r2;
|
|
var value;
|
|
var property;
|
|
if (a0) {
|
|
value = a0.match(RegExp('^(([^:/?#]+):)?(\\/\\/([^/?#]*))?([^?#]*)(\\?([^#]*))?(#(.*))?$', ''));
|
|
if (value) {
|
|
property = value[6];
|
|
r3 = property || '';
|
|
property = value[8];
|
|
r2 = property || '';
|
|
return {host: value[4], path: value[5], protocol: value[2], search: r3, hash: r2,
|
|
relative: value[5] + r3 + r2};
|
|
}
|
|
}
|
|
return {};
|
|
}
|
|
|
|
global.__d(_fun60112, 7451, []) /* metro module 7451 */;
|