diff --git a/packages/twenty-server/package.json b/packages/twenty-server/package.json index 8e1e69eab0..5b5c53e794 100644 --- a/packages/twenty-server/package.json +++ b/packages/twenty-server/package.json @@ -21,7 +21,6 @@ "@nestjs/devtools-integration": "^0.1.6", "@nestjs/graphql": "patch:@nestjs/graphql@12.1.1#./patches/@nestjs+graphql+12.1.1.patch", "@ptc-org/nestjs-query-graphql": "patch:@ptc-org/nestjs-query-graphql@4.2.0#./patches/@ptc-org+nestjs-query-graphql+4.2.0.patch", - "@types/lodash.lowerfirst": "^4.3.9", "cache-manager": "^5.4.0", "cache-manager-redis-yet": "^4.1.2", "class-validator": "patch:class-validator@0.14.0#./patches/class-validator+0.14.0.patch", @@ -31,7 +30,6 @@ "langchain": "^0.2.6", "langfuse-langchain": "^3.11.2", "lodash.differencewith": "^4.5.0", - "lodash.lowerfirst": "^4.3.1", "lodash.omitby": "^4.6.0", "lodash.uniq": "^4.5.0", "lodash.uniqby": "^4.7.0", diff --git a/packages/twenty-server/src/engine/twenty-orm/factories/entity-schema.factory.ts b/packages/twenty-server/src/engine/twenty-orm/factories/entity-schema.factory.ts index 03bf94562c..daf83b09ff 100644 --- a/packages/twenty-server/src/engine/twenty-orm/factories/entity-schema.factory.ts +++ b/packages/twenty-server/src/engine/twenty-orm/factories/entity-schema.factory.ts @@ -1,7 +1,6 @@ import { Injectable } from '@nestjs/common'; import { EntitySchema } from 'typeorm'; -import lowerFirst from 'lodash.lowerfirst'; import { EntitySchemaColumnFactory } from 'src/engine/twenty-orm/factories/entity-schema-column.factory'; import { EntitySchemaRelationFactory } from 'src/engine/twenty-orm/factories/entity-schema-relation.factory'; @@ -72,7 +71,7 @@ export class EntitySchemaFactory { WorkspaceEntitiesStorage.setEntitySchema( workspaceId, - lowerFirst(objectMetadata.nameSingular), + objectMetadata.nameSingular, entitySchema, ); diff --git a/packages/twenty-server/src/engine/twenty-orm/utils/determine-relation-details.util.ts b/packages/twenty-server/src/engine/twenty-orm/utils/determine-relation-details.util.ts index 345374dcdd..282c2ac26e 100644 --- a/packages/twenty-server/src/engine/twenty-orm/utils/determine-relation-details.util.ts +++ b/packages/twenty-server/src/engine/twenty-orm/utils/determine-relation-details.util.ts @@ -1,4 +1,3 @@ -import lowerFirst from 'lodash.lowerfirst'; import { RelationType } from 'typeorm/metadata/types/RelationTypes'; import { RelationMetadataEntity } from 'src/engine/metadata-modules/relation-metadata/relation-metadata.entity'; @@ -47,8 +46,8 @@ export async function determineRelationDetails( return { relationType, - target: lowerFirst(toObjectMetadata.nameSingular), - inverseSide: lowerFirst(fromObjectMetadata.nameSingular), + target: toObjectMetadata.nameSingular, + inverseSide: fromObjectMetadata.nameSingular, joinColumn: // TODO: This will work for now but we need to handle this better in the future for custom names on the join column relationType === 'many-to-one' || diff --git a/yarn.lock b/yarn.lock index 4083ce9a38..122784dacd 100644 --- a/yarn.lock +++ b/yarn.lock @@ -17533,15 +17533,6 @@ __metadata: languageName: node linkType: hard -"@types/lodash.lowerfirst@npm:^4.3.9": - version: 4.3.9 - resolution: "@types/lodash.lowerfirst@npm:4.3.9" - dependencies: - "@types/lodash": "npm:*" - checksum: ff5db798906f8947a85d60e7be1ea205cb1a24f51568b646f7f0b0c173e2719ea5ab942ba09e82eea4e8334fb92fffe94d7a9b61c3949403824a0b07f35f5e7c - languageName: node - linkType: hard - "@types/lodash.mapvalues@npm:^4.6.9": version: 4.6.9 resolution: "@types/lodash.mapvalues@npm:4.6.9" @@ -35220,13 +35211,6 @@ __metadata: languageName: node linkType: hard -"lodash.lowerfirst@npm:^4.3.1": - version: 4.3.1 - resolution: "lodash.lowerfirst@npm:4.3.1" - checksum: 25b148bfbeb4fc0c6f2616728d4b62fd615864b616cec838ee6877e0da609dc8bf9231a0d03799f41d9e0952dcb9471da777ea9ded4915e2d3cc89bf8c8accf8 - languageName: node - linkType: hard - "lodash.mapvalues@npm:^4.6.0": version: 4.6.0 resolution: "lodash.mapvalues@npm:4.6.0" @@ -47845,7 +47829,6 @@ __metadata: "@types/lodash.isempty": "npm:^4.4.7" "@types/lodash.isequal": "npm:^4.5.8" "@types/lodash.isobject": "npm:^3.0.7" - "@types/lodash.lowerfirst": "npm:^4.3.9" "@types/lodash.omit": "npm:^4.5.9" "@types/lodash.omitby": "npm:^4.6.9" "@types/lodash.snakecase": "npm:^4.1.7" @@ -47862,7 +47845,6 @@ __metadata: langchain: "npm:^0.2.6" langfuse-langchain: "npm:^3.11.2" lodash.differencewith: "npm:^4.5.0" - lodash.lowerfirst: "npm:^4.3.1" lodash.omitby: "npm:^4.6.0" lodash.uniq: "npm:^4.5.0" lodash.uniqby: "npm:^4.7.0"