refactor(server): events (#13003)

* refactor(server): events

* chore: better type

---------

Co-authored-by: Daniel Dietzler <mail@ddietzler.dev>
This commit is contained in:
Jason Rasmussen 2024-09-30 10:35:11 -04:00 committed by GitHub
parent 95c67949f7
commit a2d457b01d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
28 changed files with 260 additions and 259 deletions

View file

@ -1,5 +1,5 @@
import { Injectable } from '@nestjs/common';
import { OnEmit } from 'src/decorators';
import { OnEvent } from 'src/decorators';
import { ArgOf } from 'src/interfaces/event.interface';
import { IDeleteFilesJob, JobName } from 'src/interfaces/job.interface';
import { AssetService } from 'src/services/asset.service';
@ -43,7 +43,7 @@ export class MicroservicesService {
private versionService: VersionService,
) {}
@OnEmit({ event: 'app.bootstrap' })
@OnEvent({ name: 'app.bootstrap' })
async onBootstrap(app: ArgOf<'app.bootstrap'>) {
if (app !== 'microservices') {
return;