mirror of https://github.com/VERT-sh/VERT.git
fix: conversion casing
This commit is contained in:
parent
13b2f01259
commit
577237177a
|
@ -34,7 +34,6 @@ export class VertFile {
|
||||||
}
|
}
|
||||||
|
|
||||||
public async convert() {
|
public async convert() {
|
||||||
console.log(this.converter);
|
|
||||||
if (!this.converter) throw new Error("No converter found");
|
if (!this.converter) throw new Error("No converter found");
|
||||||
this.result = null;
|
this.result = null;
|
||||||
this.progress = 0;
|
this.progress = 0;
|
||||||
|
|
|
@ -20,7 +20,7 @@
|
||||||
const from =
|
const from =
|
||||||
"." + f.name.toLowerCase().split(".").slice(-1);
|
"." + f.name.toLowerCase().split(".").slice(-1);
|
||||||
const converter = converters.find((c) =>
|
const converter = converters.find((c) =>
|
||||||
c.supportedFormats.includes(from),
|
c.supportedFormats.includes(from.toLowerCase()),
|
||||||
);
|
);
|
||||||
if (!converter) resolve();
|
if (!converter) resolve();
|
||||||
const to =
|
const to =
|
||||||
|
|
|
@ -35,8 +35,8 @@
|
||||||
const file = files.files[i];
|
const file = files.files[i];
|
||||||
const converter = converters.find(
|
const converter = converters.find(
|
||||||
(c) =>
|
(c) =>
|
||||||
c.supportedFormats.includes(file.from) &&
|
c.supportedFormats.includes(file.from.toLowerCase()) &&
|
||||||
c.supportedFormats.includes(file.to),
|
c.supportedFormats.includes(file.to.toLowerCase()),
|
||||||
);
|
);
|
||||||
if (!converter) throw new Error("No converter found");
|
if (!converter) throw new Error("No converter found");
|
||||||
required.push(converter);
|
required.push(converter);
|
||||||
|
|
Loading…
Reference in New Issue