2022-02-27 11:07:39 +09:00
|
|
|
import { ObjectStorageFileJobData } from '@/queue/types.js';
|
|
|
|
|
import Bull from 'bull';
|
|
|
|
|
import { deleteObjectStorageFile } from '@/services/drive/delete-file.js';
|
2019-05-27 16:54:47 +09:00
|
|
|
|
2021-05-08 18:56:21 +09:00
|
|
|
export default async (job: Bull.Job<ObjectStorageFileJobData>) => {
|
2019-05-27 16:54:47 +09:00
|
|
|
const key: string = job.data.key;
|
|
|
|
|
|
2019-07-01 21:12:14 +09:00
|
|
|
await deleteObjectStorageFile(key);
|
2019-05-27 16:54:47 +09:00
|
|
|
|
|
|
|
|
return 'Success';
|
|
|
|
|
};
|