Isolate result type / class

This commit is contained in:
DominikDoom
2025-07-12 18:39:06 +02:00
parent 781cea83a0
commit 8a574ec5e1
11 changed files with 60 additions and 60 deletions

View File

@@ -24,7 +24,7 @@ class LycoParser extends BaseTagParser {
let lastSlash = text.lastIndexOf("/") > -1 ? text.lastIndexOf("/") : -1;
let name = text.substring(lastSlash + 1, lastDot);
let result = new AutocompleteResult(name, ResultType.lyco)
let result = new TAC.AutocompleteResult(name, TAC.ResultType.lyco)
result.meta = "Lyco";
result.sortKey = t[1];
result.hash = t[2];
@@ -48,7 +48,7 @@ async function load() {
}
async function sanitize(tagType, text) {
if (tagType === ResultType.lyco) {
if (tagType === TAC.ResultType.lyco) {
let multiplier = TAC.CFG.extraNetworksDefaultMultiplier;
let info = await TacUtils.fetchAPI(`tacapi/v1/lyco-info/${text}`)
if (info && info["preferred weight"]) {