mirror of
https://github.com/Equicord/Equicord.git
synced 2025-02-07 12:03:47 -05:00
Revert "Language Blacklist for MessageTranslate"
This reverts commit b10429e0ae
.
This commit is contained in:
parent
b10429e0ae
commit
6b4e0d54a9
1 changed files with 0 additions and 7 deletions
|
@ -22,16 +22,9 @@ const settings = definePluginSettings(
|
|||
default: "0.8",
|
||||
restartNeeded: true
|
||||
},
|
||||
languageBlacklist: {
|
||||
type: OptionType.STRING,
|
||||
description: "Language codes to disable functionality in (separate with comma)",
|
||||
default: "",
|
||||
restartNeeded: true
|
||||
},
|
||||
});
|
||||
|
||||
async function translateAPI(sourceLang: string, targetLang: string, text: string): Promise<any> {
|
||||
if (settings.store.languageBlacklist.includes(sourceLang)) return;
|
||||
|
||||
const url = `https://translate.googleapis.com/translate_a/single?client=gtx&sl=${sourceLang}&tl=${targetLang}&dt=t&dj=1&q=${encodeURIComponent(text)}`;
|
||||
const response = await fetch(url);
|
||||
|
|
Loading…
Reference in a new issue