This commit is contained in:
tamaina 2023-02-28 17:12:01 +00:00
parent d5f5f4023c
commit 969d27e1b3
3 changed files with 7 additions and 1 deletions

View File

@ -217,6 +217,9 @@ function correctFilename(filename, ext) {
if (ext === 'jpg' && filename.endsWith('.jpeg')) {
return filename;
}
if (ext === 'tif' && filename.endsWith('.tiff')) {
return filename;
}
return `${filename}${dotExt}`;
}
function contentDisposition(type, filename) {

View File

@ -1,6 +1,6 @@
{
"name": "misskey-media-proxy",
"version": "0.0.15",
"version": "0.0.16",
"description": "The Media Proxy for Misskey",
"main": "built/index.js",
"packageManager": "pnpm@7.26.0",

View File

@ -273,6 +273,9 @@ function correctFilename(filename: string, ext: string | null) {
if (ext === 'jpg' && filename.endsWith('.jpeg')) {
return filename;
}
if (ext === 'tif' && filename.endsWith('.tiff')) {
return filename;
}
return `${filename}${dotExt}`;
}