mirror of
https://github.com/aljazceru/ditto.git
synced 2026-02-23 05:56:03 +01:00
refactor: make provider lowercase because supporting case insensitive is allegedly protocol bloat
This commit is contained in:
@@ -11,7 +11,7 @@ export const translatorMiddleware: AppMiddleware = async (c, next) => {
|
||||
const translationProvider = Conf.translationProvider;
|
||||
|
||||
switch (translationProvider) {
|
||||
case 'DeepL'.toLowerCase():
|
||||
case 'deepl':
|
||||
if (apiKey) {
|
||||
c.set(
|
||||
'translator',
|
||||
@@ -19,7 +19,7 @@ export const translatorMiddleware: AppMiddleware = async (c, next) => {
|
||||
);
|
||||
}
|
||||
break;
|
||||
case 'Libretranslate'.toLowerCase():
|
||||
case 'libretranslate':
|
||||
if (apiKey) {
|
||||
c.set(
|
||||
'translator',
|
||||
|
||||
Reference in New Issue
Block a user