Fix workspace/user deletion (#2648)

* Fix workspace/user deletion

* remove logs

* add defaultWorkspace check
This commit is contained in:
Weiko
2023-11-22 17:12:46 +01:00
committed by GitHub
parent ac2fedb148
commit ccaa96bc58
12 changed files with 90 additions and 19 deletions

View File

@ -46,12 +46,18 @@ export class RelationMetadataEntity implements RelationMetadataInterface {
@ManyToOne(
() => ObjectMetadataEntity,
(object: ObjectMetadataEntity) => object.fromRelations,
{
onDelete: 'CASCADE',
},
)
fromObjectMetadata: ObjectMetadataEntity;
@ManyToOne(
() => ObjectMetadataEntity,
(object: ObjectMetadataEntity) => object.toRelations,
{
onDelete: 'CASCADE',
},
)
toObjectMetadata: ObjectMetadataEntity;