decord/source/modules/activities/utils/useCurrentEmbeddedApplication.tsx

32 lines
973 B
TypeScript
Raw Normal View History

2026-08-25 06:04:03 +00:00
// Module ID: 10803
// Function ID: 10804
2026-07-20 16:05:17 +00:00
// Name: useCurrentEmbeddedApplication
2026-08-25 06:04:03 +00:00
// Dependencies: [32, 10804, 5840, 2]
2026-07-20 16:05:17 +00:00
// Exports: default
2026-08-25 06:04:03 +00:00
// Module 10803 (useCurrentEmbeddedApplication)
import useGetOrFetchApplicationsDefault from "useGetOrFetchApplications" /* 5840 */;
import useCurrentEmbeddedActivityDefault from "useCurrentEmbeddedActivity" /* 10804 */;
2026-08-24 06:08:38 +00:00
import closure_2 from "_slicedToArray" /* 32 */;
2026-07-23 10:11:24 +00:00
2026-08-24 06:08:38 +00:00
const result = require("set").fileFinishedImporting("modules/activities/utils/useCurrentEmbeddedApplication.tsx");
2026-07-20 16:05:17 +00:00
export default function useCurrentEmbeddedApplication() {
let obj = arg0;
if (arg0 === undefined) {
obj = {};
}
let flag = obj.fetchesApplication;
if (flag === undefined) {
flag = true;
}
2026-08-24 06:08:38 +00:00
const tmp = useCurrentEmbeddedActivityDefault();
2026-07-20 16:05:17 +00:00
if (null == tmp) {
let items = [];
} else {
items = [tmp.applicationId];
}
2026-08-24 06:08:38 +00:00
const first = callback(useGetOrFetchApplicationsDefault(items, flag), 1)[0];
2026-07-29 08:29:29 +00:00
return first;
2026-07-20 16:05:17 +00:00
};