Fix bug with font name conversion

This commit is contained in:
Sofía Aritz 2023-05-20 22:01:45 +02:00
parent ea310a29db
commit b21fd3c650

View file

@ -15,7 +15,7 @@ async function font_metadata_folder(folder: string, font: string, mirror: string
}
export async function retrieve_font_metadata(font: string, mirror: string): Promise<{ url: string, metadata: FontMetadata }> {
let fontname = font.replace(" ", "").toLowerCase()
let fontname = font.replaceAll(" ", "").toLowerCase()
let [url, raw_metadata] = (await font_metadata_folder("ofl", fontname, mirror))
|| (await font_metadata_folder("ufl", fontname, mirror))
|| (await font_metadata_folder("apache", fontname, mirror))