7154 deleted event is not emitted when calling destroyone (#7159)

Closes #7154
This commit is contained in:
Raphaël Bosi
2024-09-27 15:52:04 +02:00
committed by GitHub
parent ca906bbf6b
commit c9c2f32922
12 changed files with 128 additions and 15 deletions

View File

@ -8,7 +8,7 @@ import { TwentyORMManager } from 'src/engine/twenty-orm/twenty-orm.manager';
import { WorkspaceEventEmitter } from 'src/engine/workspace-event-emitter/workspace-event-emitter';
import { MessageChannelWorkspaceEntity } from 'src/modules/messaging/common/standard-objects/message-channel.workspace-entity';
@WorkspaceQueryHook(`connectedAccount.deleteOne`)
@WorkspaceQueryHook(`connectedAccount.destroyOne`)
export class ConnectedAccountDeleteOnePreQueryHook
implements WorkspaceQueryHookInstance
{
@ -34,7 +34,7 @@ export class ConnectedAccountDeleteOnePreQueryHook
});
this.workspaceEventEmitter.emit(
'messageChannel.deleted',
'messageChannel.destroyed',
messageChannels.map(
(messageChannel) =>
({