DeepL: fixed NPE

This commit is contained in:
M66B 2023-11-10 09:30:11 +01:00
parent 05b950a95b
commit 5ded10a29a
1 changed files with 1 additions and 1 deletions

View File

@ -347,7 +347,7 @@ public class DeepL {
}
private static String getBaseUri(String key) {
String domain = (key.endsWith(":fx") ? "api-free.deepl.com" : "api.deepl.com");
String domain = (key != null && key.endsWith(":fx") ? "api-free.deepl.com" : "api.deepl.com");
return "https://" + domain + "/v2/";
}