mirror of
https://github.com/upscayl/upscayl.git
synced 2024-11-12 01:40:53 +01:00
Fix name logic
This commit is contained in:
parent
938bc0d83a
commit
aa84f7de1d
@ -55,9 +55,14 @@ const doubleUpscayl = async (event, payload: DoubleUpscaylPayload) => {
|
||||
const customWidth = useCustomWidth ? payload.customWidth : "";
|
||||
|
||||
const outFile =
|
||||
outputDir + slash + fileName + "_upscayl_" + useCustomWidth
|
||||
? `${customWidth}px_`
|
||||
: `${scale}x_` + model + "." + saveImageAs;
|
||||
outputDir +
|
||||
slash +
|
||||
fileName +
|
||||
"_upscayl_" +
|
||||
(useCustomWidth ? `${customWidth}px_` : `${scale}x_`) +
|
||||
model +
|
||||
"." +
|
||||
saveImageAs;
|
||||
|
||||
// UPSCALE
|
||||
let upscayl = spawnUpscayl(
|
||||
|
@ -64,9 +64,14 @@ const imageUpscayl = async (event, payload: ImageUpscaylPayload) => {
|
||||
const scale = payload.scale;
|
||||
|
||||
const outFile =
|
||||
outputDir + slash + fileName + "_upscayl_" + useCustomWidth
|
||||
? `${customWidth}px_`
|
||||
: `${scale}x_` + model + "." + saveImageAs;
|
||||
outputDir +
|
||||
slash +
|
||||
fileName +
|
||||
"_upscayl_" +
|
||||
(useCustomWidth ? `${customWidth}px_` : `${scale}x_`) +
|
||||
model +
|
||||
"." +
|
||||
saveImageAs;
|
||||
|
||||
// UPSCALE
|
||||
if (fs.existsSync(outFile) && !overwrite) {
|
||||
|
Loading…
Reference in New Issue
Block a user