fix: remove rogue console.log

This commit is contained in:
diced 2023-03-21 19:51:02 -07:00
parent 6ada79017a
commit a81f797266
No known key found for this signature in database
GPG key ID: 370BD1BA142842D1
3 changed files with 1 additions and 3 deletions

View file

@ -19,7 +19,6 @@ export default function KaTeX({ code, ...props }) {
</Alert>
);
};
// dynamic
useEffect(() => {
(async () => {

View file

@ -6,7 +6,6 @@ import uuid from './uuid';
export type NameFormat = 'random' | 'date' | 'uuid' | 'name' | 'gfycat';
export const NameFormats: NameFormat[] = ['random', 'date', 'uuid', 'name', 'gfycat'];
export default async function formatFileName(nameFormat: NameFormat, originalName?: string) {
console.log(nameFormat, originalName);
switch (nameFormat) {
case 'random':
return random();

View file

@ -233,7 +233,7 @@ async function handler(req: NextApiReq, res: NextApiRes) {
if (zconfig.uploader.disabled_extensions.includes(ext))
return res.badRequest(`file[${i}]: disabled extension recieved: ${ext}`);
let fileName = await formatFileName(format, file.originalname);
console.log(fileName);
if (req.headers['x-zipline-filename']) {
fileName = req.headers['x-zipline-filename'] as string;
const existing = await prisma.file.findFirst({