mirror of
https://github.com/open-reception/appointment-booking-software.git
synced 2026-08-17 21:25:52 +02:00
Prevent data leak from get tenant endpoint
This commit is contained in:
@@ -471,7 +471,20 @@ export const GET: RequestHandler = async ({ params, locals }) => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
return json({
|
return json({
|
||||||
tenant: tenantData,
|
tenant: {
|
||||||
|
id: tenantData.id,
|
||||||
|
createdAt: tenantData.createdAt,
|
||||||
|
updatedAt: tenantData.updatedAt,
|
||||||
|
languages: tenantData.languages,
|
||||||
|
defaultLanguage: tenantData.defaultLanguage,
|
||||||
|
shortName: tenantData.shortName,
|
||||||
|
longName: tenantData.longName,
|
||||||
|
descriptions: tenantData.descriptions || {},
|
||||||
|
domain: tenantData.domain,
|
||||||
|
logo: tenantData.logo,
|
||||||
|
setupState: tenantData.setupState,
|
||||||
|
links: tenantData.links,
|
||||||
|
},
|
||||||
});
|
});
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
logError(log)("Error getting tenant details", error, locals.user?.id, params.id);
|
logError(log)("Error getting tenant details", error, locals.user?.id, params.id);
|
||||||
|
|||||||
Reference in New Issue
Block a user