From 3046b87b768ef93682c6e390395f79beb75b7457 Mon Sep 17 00:00:00 2001 From: ThatOneCalculator Date: Mon, 25 Jul 2022 14:02:46 -0700 Subject: [PATCH] .js --- .../src/server/api/endpoints/drive/files/upload-from-url.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/backend/src/server/api/endpoints/drive/files/upload-from-url.ts b/packages/backend/src/server/api/endpoints/drive/files/upload-from-url.ts index 48fa4a6a9..88a448f21 100644 --- a/packages/backend/src/server/api/endpoints/drive/files/upload-from-url.ts +++ b/packages/backend/src/server/api/endpoints/drive/files/upload-from-url.ts @@ -1,8 +1,8 @@ import { uploadFromUrl } from '@/services/drive/upload-from-url.js'; +import define from '../../../define.js'; import { DriveFiles } from '@/models/index.js'; import { publishMainStream } from '@/services/stream.js'; import { HOUR } from '@/const.js'; -import define from '@/server/api/define'; export const meta = { tags: ['drive'], @@ -33,8 +33,8 @@ export const paramDef = { } as const; // eslint-disable-next-line import/no-default-export -export default define(meta, paramDef, async (ps, user, _1, _2, _3, ip, headers) => { - uploadFromUrl({ url: ps.url, user, folderId: ps.folderId, sensitive: ps.isSensitive, force: ps.force, comment: ps.comment, requestIp: ip, requestHeaders: headers }).then(file => { +export default define(meta, paramDef, async (ps, user) => { + uploadFromUrl({ url: ps.url, user, folderId: ps.folderId, sensitive: ps.isSensitive, force: ps.force, comment: ps.comment }).then(file => { DriveFiles.pack(file, { self: true }).then(packedFile => { publishMainStream(user.id, 'urlUploadFinished', { marker: ps.marker,