Files
nebula.js/commands/serve/web/utils/authRequests.js
Ahmad Mirzaei 4954ac4ff4 refactor: hub components (#967)
* refactor: hub components
2022-10-20 16:27:43 +02:00

10 lines
266 B
JavaScript

export const checkIfAuthorized = async () => {
const { isAuthorized } = await (await fetch('/isAuthorized')).json();
return { isAuthorized };
};
export const getAppList = async () => {
const apps = await (await fetch(`/apps`)).json();
return apps || [];
};