Files
calendar/packages/app-store/_utils/getAppKeysFromSlug.ts
T
alannncGitHubzomarskodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
525ce0d075 Fix/office365 api call (#3534)
* WIP fixes for handling office365 api call

* First working version microsoft api call handling

* Remove logs

* Clean up and improve function names

* Clean up

* Remove log

* Fix function missing its correct name

* Fix direct return of statement

* Cleanup

* Simplify with private fetcher

* Update CalendarService.ts

* Update getOfficeAppKeys.ts

Co-authored-by: zomars <zomars@me.com>
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
2022-07-27 19:12:42 +00:00

11 lines
286 B
TypeScript

import type { Prisma } from "@prisma/client";
import prisma from "@calcom/prisma";
async function getAppKeysFromSlug(slug: string) {
const app = await prisma.app.findUnique({ where: { slug } });
return (app?.keys || {}) as Prisma.JsonObject;
}
export default getAppKeysFromSlug;