Skip to content

Commit 7f4f91d

Browse files
committed
refactor(interface): reorganize
1 parent d3dd1b7 commit 7f4f91d

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

src/decorators/worker-hooks.decorators.ts

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,12 @@
11
import { SetMetadata } from '@nestjs/common';
2-
import { WorkerEventMap } from 'graphile-worker';
2+
import { WorkerEventName } from '../interfaces/worker.interfaces';
33

4-
export const GRAPHILE_WORKER_LISTENER = Symbol.for('GraphileWorkerListener');
4+
export const GRAPHILE_WORKER_LISTENER = Symbol.for('GRAPHILE_WORKER_LISTENER');
55

66
export const GRAPHILE_WORKER_ON_WORKER_EVENT = Symbol.for(
7-
'GraphileWorkerJobEvent',
7+
'GRAPHILE_WORKER_ON_WORKER_EVENT',
88
);
99

10-
export type WorkerEventName = keyof WorkerEventMap;
11-
1210
export function GraphileWorkerListener(): ClassDecorator {
1311
return SetMetadata(GRAPHILE_WORKER_LISTENER, true);
1412
}
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
import { WorkerEventMap } from 'graphile-worker';
2+
export type WorkerEventName = keyof WorkerEventMap;

src/services/listener-explorer.service.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import { Injectable, Logger, OnModuleInit } from '@nestjs/common';
22
import { DiscoveryService } from '@nestjs/core';
33
import { InstanceWrapper } from '@nestjs/core/injector/instance-wrapper';
44
import { MetadataScanner } from '@nestjs/core/metadata-scanner';
5-
import { WorkerEventName } from '../decorators/worker-hooks.decorators';
5+
import { WorkerEventName } from '../interfaces/worker.interfaces';
66
import { MetadataAccessorService } from './metadata-accessor.service';
77

88
/**

0 commit comments

Comments
 (0)