なんかもうめっちゃ変えた
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
import define from '../../../define.js';
|
||||
import { createCleanRemoteFilesJob } from '@/queue/index.js';
|
||||
import { Inject, Injectable } from '@nestjs/common';
|
||||
import { Endpoint } from '@/server/api/endpoint-base.js';
|
||||
import { QueueService } from '@/core/QueueService.js';
|
||||
|
||||
export const meta = {
|
||||
tags: ['admin'],
|
||||
@@ -15,6 +16,13 @@ export const paramDef = {
|
||||
} as const;
|
||||
|
||||
// eslint-disable-next-line import/no-default-export
|
||||
export default define(meta, paramDef, async (ps, me) => {
|
||||
createCleanRemoteFilesJob();
|
||||
});
|
||||
@Injectable()
|
||||
export default class extends Endpoint<typeof meta, typeof paramDef> {
|
||||
constructor(
|
||||
private queueService: QueueService,
|
||||
) {
|
||||
super(meta, paramDef, async (ps, me) => {
|
||||
this.queueService.createCleanRemoteFilesJob();
|
||||
});
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user