2026-10-12 06:59:38 +00:00
|
|
|
// Module ID: 9205
|
|
|
|
|
// Function ID: 9206
|
2026-07-20 16:05:17 +00:00
|
|
|
// Name: authorizeConnection
|
2026-10-13 12:43:34 +00:00
|
|
|
// Dependencies: [6877, 1085, 584, 5056, 9206, 13410, 13421, 5934, 13432, 2000, 5763, 13434, 8491, 4806, 6875, 2]
|
2026-07-20 16:05:17 +00:00
|
|
|
// Exports: default
|
|
|
|
|
|
2026-10-12 06:59:38 +00:00
|
|
|
// Module 9205 (authorizeConnection)
|
2026-10-03 08:58:59 +00:00
|
|
|
import DispatcherDefault from "Dispatcher" /* 584 */;
|
|
|
|
|
import Constants from "Constants" /* 1085 */;
|
2026-10-10 08:08:14 +00:00
|
|
|
import LinkingDefault from "Linking" /* 4806 */;
|
2026-10-12 06:59:38 +00:00
|
|
|
import Constants2 from "Constants" /* 6877 */;
|
2026-09-10 05:38:07 +00:00
|
|
|
import size from "module_2" /* 2 */;
|
2026-07-23 10:11:24 +00:00
|
|
|
|
2026-09-10 05:38:07 +00:00
|
|
|
let closure_3 = Constants2.GUILD_ROLE_CONNECTION_APPLICATION_CONNECTION_TYPE;
|
|
|
|
|
const PlatformTypes = Constants.PlatformTypes;
|
|
|
|
|
const result = size.fileFinishedImporting("modules/connections/authorizeConnection.native.tsx");
|
2026-07-20 16:05:17 +00:00
|
|
|
|
2026-07-29 08:29:29 +00:00
|
|
|
export default function authorizeConnection(overrideUrl) {
|
2026-10-03 08:58:59 +00:00
|
|
|
let _location;
|
|
|
|
|
let items2;
|
|
|
|
|
let onClose;
|
|
|
|
|
let platformType;
|
|
|
|
|
const handleModalClose6 = function handleModalClose() {
|
|
|
|
|
if (onClose != null) {
|
|
|
|
|
tmp();
|
|
|
|
|
}
|
|
|
|
|
const obj = DispatcherDefault;
|
|
|
|
|
obj.unsubscribe("MODAL_POP", handleModalClose);
|
|
|
|
|
};
|
2026-07-29 08:29:29 +00:00
|
|
|
({ platformType, location: _location, onClose } = overrideUrl);
|
|
|
|
|
overrideUrl = overrideUrl.overrideUrl;
|
|
|
|
|
const successRedirect = overrideUrl.successRedirect;
|
2026-10-03 08:58:59 +00:00
|
|
|
const tmp = PlatformTypes;
|
2026-07-20 16:05:17 +00:00
|
|
|
if (platformType === PlatformTypes.LEAGUE_OF_LEGENDS) {
|
2026-07-29 08:29:29 +00:00
|
|
|
platformType = tmp.RIOT_GAMES;
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
|
|
|
|
if (null == _location) {
|
|
|
|
|
_location = "mobile";
|
|
|
|
|
}
|
2026-10-03 08:58:59 +00:00
|
|
|
if (platformType === tmp.XBOX) {
|
2026-10-10 08:08:14 +00:00
|
|
|
const obj15 = overrideUrl(5056);
|
2026-10-03 08:58:59 +00:00
|
|
|
obj15.hideActionSheet();
|
2026-07-20 16:05:17 +00:00
|
|
|
const items = [_location];
|
2026-10-12 06:59:38 +00:00
|
|
|
const obj16 = overrideUrl(9206);
|
2026-10-03 08:58:59 +00:00
|
|
|
obj16.showModal(items);
|
|
|
|
|
const tmp23 = overrideUrl;
|
2026-07-29 08:29:29 +00:00
|
|
|
if (null != onClose) {
|
2026-10-03 08:58:59 +00:00
|
|
|
const handleModalClose = handleModalClose6;
|
|
|
|
|
const tmp23Result = tmp23(584);
|
|
|
|
|
const subscription = tmp23Result.subscribe("MODAL_POP", handleModalClose);
|
2026-07-29 08:29:29 +00:00
|
|
|
}
|
2026-07-20 16:05:17 +00:00
|
|
|
} else {
|
2026-07-29 08:29:29 +00:00
|
|
|
if (platformType !== tmp.PLAYSTATION) {
|
|
|
|
|
if (platformType !== tmp.PLAYSTATION_STAGING) {
|
|
|
|
|
if (platformType === tmp.CRUNCHYROLL) {
|
2026-10-10 08:08:14 +00:00
|
|
|
const obj11 = overrideUrl(5056);
|
2026-10-03 08:58:59 +00:00
|
|
|
obj11.hideActionSheet();
|
2026-07-20 16:05:17 +00:00
|
|
|
const items1 = [_location];
|
2026-10-13 12:43:34 +00:00
|
|
|
const obj12 = overrideUrl(13421);
|
2026-10-03 08:58:59 +00:00
|
|
|
obj12.showModal(items1);
|
|
|
|
|
const tmp15 = overrideUrl;
|
2026-07-29 08:29:29 +00:00
|
|
|
if (null != onClose) {
|
2026-10-03 08:58:59 +00:00
|
|
|
const handleModalClose4 = handleModalClose6;
|
|
|
|
|
const tmp15Result = tmp15(584);
|
|
|
|
|
const subscription1 = tmp15Result.subscribe("MODAL_POP", handleModalClose4);
|
2026-07-29 08:29:29 +00:00
|
|
|
}
|
|
|
|
|
} else if (platformType === tmp.DOMAIN) {
|
2026-10-10 08:08:14 +00:00
|
|
|
const obj8 = overrideUrl(5056);
|
2026-10-03 08:58:59 +00:00
|
|
|
obj8.hideActionSheet();
|
|
|
|
|
let obj = { locationStack: items2 };
|
|
|
|
|
items2 = [_location];
|
2026-10-10 08:08:14 +00:00
|
|
|
const obj9 = overrideUrl(5934);
|
2026-10-13 12:43:34 +00:00
|
|
|
obj9.pushLazy(onClose(2000)(13432, dependencyMap.paths), obj);
|
2026-07-29 08:29:29 +00:00
|
|
|
const tmp10 = overrideUrl;
|
|
|
|
|
if (null != onClose) {
|
2026-10-03 08:58:59 +00:00
|
|
|
const handleModalClose3 = handleModalClose6;
|
|
|
|
|
const tmp10Result = tmp10(584);
|
|
|
|
|
const subscription2 = tmp10Result.subscribe("MODAL_POP", handleModalClose3);
|
2026-07-29 08:29:29 +00:00
|
|
|
}
|
2026-07-20 16:05:17 +00:00
|
|
|
} else {
|
2026-10-10 08:08:14 +00:00
|
|
|
const obj18 = overrideUrl(5763);
|
2026-10-03 08:58:59 +00:00
|
|
|
const value = obj18.get(platformType);
|
2026-07-20 16:05:17 +00:00
|
|
|
let isFederated;
|
2026-10-03 08:58:59 +00:00
|
|
|
const tmp29 = dependencyMap;
|
2026-07-29 08:29:29 +00:00
|
|
|
if (value != null) {
|
2026-07-20 16:05:17 +00:00
|
|
|
isFederated = value.isFederated;
|
|
|
|
|
}
|
|
|
|
|
if (true === isFederated) {
|
2026-10-10 08:08:14 +00:00
|
|
|
const tmp28Result = overrideUrl(5056);
|
2026-10-03 08:58:59 +00:00
|
|
|
tmp28Result.hideActionSheet();
|
2026-09-10 05:38:07 +00:00
|
|
|
const obj2 = { platformType, location: _location, successRedirect };
|
2026-10-10 08:08:14 +00:00
|
|
|
const tmp28Result4 = overrideUrl(5934);
|
2026-10-13 12:43:34 +00:00
|
|
|
tmp28Result4.pushLazy(onClose(2000)(13434, tmp29.paths), obj2);
|
2026-07-29 08:29:29 +00:00
|
|
|
if (null != onClose) {
|
2026-10-03 08:58:59 +00:00
|
|
|
const handleModalClose2 = handleModalClose6;
|
|
|
|
|
const tmp28Result5 = overrideUrl(584);
|
|
|
|
|
const subscription3 = tmp28Result5.subscribe("MODAL_POP", handleModalClose2);
|
2026-07-29 08:29:29 +00:00
|
|
|
}
|
2026-07-20 16:05:17 +00:00
|
|
|
} else {
|
|
|
|
|
if (null != overrideUrl) {
|
|
|
|
|
if (platformType === closure_3) {
|
2026-09-10 05:38:07 +00:00
|
|
|
const obj4 = {
|
|
|
|
|
shouldConfirm: true,
|
|
|
|
|
href: overrideUrl,
|
|
|
|
|
onConfirm() {
|
2026-10-03 08:58:59 +00:00
|
|
|
const obj = LinkingDefault;
|
|
|
|
|
obj.openURL(overrideUrl);
|
2026-09-10 05:38:07 +00:00
|
|
|
}
|
2026-07-20 16:05:17 +00:00
|
|
|
};
|
2026-10-12 06:59:38 +00:00
|
|
|
const obj3 = onClose(8491);
|
2026-10-03 08:58:59 +00:00
|
|
|
obj3.handleClick(obj4);
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
|
|
|
|
}
|
2026-09-10 05:38:07 +00:00
|
|
|
const obj5 = { location: _location, successRedirect };
|
2026-10-12 06:59:38 +00:00
|
|
|
const tmp28Result6 = overrideUrl(6875);
|
2026-10-03 08:58:59 +00:00
|
|
|
const authorizeResult = tmp28Result6.authorize(platformType, obj5);
|
|
|
|
|
authorizeResult.then((body) => {
|
2026-07-20 16:05:17 +00:00
|
|
|
const url = body.body.url;
|
|
|
|
|
if (null != url) {
|
2026-10-03 08:58:59 +00:00
|
|
|
const obj = overrideUrl(dependencyMap[13]);
|
|
|
|
|
obj.openURL(url);
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
2026-10-10 08:08:14 +00:00
|
|
|
const obj13 = overrideUrl(5056);
|
2026-10-03 08:58:59 +00:00
|
|
|
obj13.hideActionSheet();
|
2026-07-20 16:05:17 +00:00
|
|
|
const items3 = [_location];
|
2026-10-13 12:43:34 +00:00
|
|
|
const obj14 = overrideUrl(13410);
|
2026-10-03 08:58:59 +00:00
|
|
|
obj14.showModal(items3, platformType);
|
|
|
|
|
const tmp19 = overrideUrl;
|
2026-07-29 08:29:29 +00:00
|
|
|
if (null != onClose) {
|
2026-10-03 08:58:59 +00:00
|
|
|
const handleModalClose5 = handleModalClose6;
|
|
|
|
|
const tmp19Result = tmp19(584);
|
|
|
|
|
const subscription4 = tmp19Result.subscribe("MODAL_POP", handleModalClose5);
|
2026-07-29 08:29:29 +00:00
|
|
|
}
|
2026-07-20 16:05:17 +00:00
|
|
|
}
|
|
|
|
|
};
|