cal/packages/app-store/appStoreMetaData.ts
Hariom Balhara 986f9dca8d
Fix: appKeys handling (#8406)
* Handle appKeys save and read correctly

* Add missing zod file for zohocrm which needs keys

* Show team invites regardless of user plan

* Linting

---------

Co-authored-by: Joe Au-Yeung <65426560+joeauyeung@users.noreply.github.com>
Co-authored-by: Keith Williams <keithwillcode@gmail.com>
Co-authored-by: zomars <zomars@me.com>
2023-04-20 21:14:50 +00:00

20 lines
619 B
TypeScript

import type { AppMeta } from "@calcom/types/App";
import { appStoreMetadata as rawAppStoreMetadata } from "./apps.metadata.generated";
type RawAppStoreMetaData = typeof rawAppStoreMetadata;
type AppStoreMetaData = {
[key in keyof RawAppStoreMetaData]: AppMeta;
};
export const appStoreMetadata = {} as AppStoreMetaData;
for (const [key, value] of Object.entries(rawAppStoreMetadata)) {
appStoreMetadata[key as keyof typeof appStoreMetadata] = {
appData: null,
dirName: "dirName" in value ? value.dirName : value.slug,
__template: "",
...value,
} as AppStoreMetaData[keyof AppStoreMetaData];
}