Removes console logs from title matching

Cleans up the code by removing console log statements used for debugging during the title matching process. This improves code readability and avoids unnecessary logging in the production environment.
This commit is contained in:
2025-04-23 10:21:26 -04:00
parent 9c51aaa2b5
commit d680c97bc6

View File

@@ -16,25 +16,12 @@ function findBestMatch(mainString: string, targets: string[]): string | null {
break; break;
} }
console.log(
"searching best match",
`'${mainString}'`,
`'${targets[i]}'`,
currentScore,
highestScore,
);
if (currentScore > highestScore) { if (currentScore > highestScore) {
highestScore = currentScore; highestScore = currentScore;
bestMatch = targets[i]; bestMatch = targets[i];
} }
} }
console.log(
"findBestMatch",
`'${mainString}'`,
`'${bestMatch}'`,
highestScore,
);
return bestMatch; return bestMatch;
} }
@@ -55,7 +42,6 @@ export const findBestMatchingTitle = (
expectedSuffix = match[1]; expectedSuffix = match[1];
} }
console.log("searching best user preferred title", userPreferred);
const userPreferredBestMatch = userPreferred const userPreferredBestMatch = userPreferred
? findBestMatch( ? findBestMatch(
userPreferred, userPreferred,
@@ -68,7 +54,6 @@ export const findBestMatchingTitle = (
), ),
) )
: null; : null;
console.log("searching best english title", english);
const englishBestMatch = english const englishBestMatch = english
? findBestMatch( ? findBestMatch(
english, english,