chore: Select organization fields to prevent logo import (#14255)
* chore: Select organization fields to prevent logo import * teams query actually doesn't use org, keep for backwards compat
This commit is contained in:
1 parent
33d0fee43e
commit
29bca76e91
2 files changed
+11
-3
No files matched your search
@@ -25,13 +25,13 @@ export async function getTeamWithMembers(args: {
|
|||||||
orgSlug?: string | null;
|
orgSlug?: string | null;
|
||||||
includeTeamLogo?: boolean;
|
includeTeamLogo?: boolean;
|
||||||
isTeamView?: boolean;
|
isTeamView?: boolean;
|
||||||
currentOrg?: Team | null;
|
currentOrg?: Pick<Team, "id"> | null;
|
||||||
/**
|
/**
|
||||||
* If true, means that you are fetching an organization and not a team
|
* If true, means that you are fetching an organization and not a team
|
||||||
*/
|
*/
|
||||||
isOrgView?: boolean;
|
isOrgView?: boolean;
|
||||||
}) {
|
}) {
|
||||||
const { id, slug, currentOrg, userId, orgSlug, isTeamView, isOrgView, includeTeamLogo } = args;
|
const { id, slug, currentOrg: _currentOrg, userId, orgSlug, isTeamView, isOrgView, includeTeamLogo } = args;
|
||||||
|
|
||||||
// This should improve performance saving already app data found.
|
// This should improve performance saving already app data found.
|
||||||
const appDataMap = new Map();
|
const appDataMap = new Map();
|
||||||
|
|||||||
@@ -349,7 +349,15 @@ export class ProfileRepository {
|
|||||||
},
|
},
|
||||||
movedFromUser: true,
|
movedFromUser: true,
|
||||||
organization: {
|
organization: {
|
||||||
include: {
|
select: {
|
||||||
|
calVideoLogo: true,
|
||||||
|
id: true,
|
||||||
|
logoUrl: true,
|
||||||
|
name: true,
|
||||||
|
slug: true,
|
||||||
|
metadata: true,
|
||||||
|
bannerUrl: true,
|
||||||
|
isPrivate: true,
|
||||||
organizationSettings: {
|
organizationSettings: {
|
||||||
select: {
|
select: {
|
||||||
lockEventTypeCreationForUsers: true,
|
lockEventTypeCreationForUsers: true,
|
||||||
|
|||||||
Reference in new issue
Block a user