mirror of
https://github.com/M66B/FairEmail.git
synced 2025-01-01 12:44:42 +00:00
DeepL: base URI
This commit is contained in:
parent
349ce9e99c
commit
e476fe04e4
1 changed files with 2 additions and 1 deletions
|
@ -316,6 +316,7 @@ public class FragmentCompose extends FragmentBase {
|
|||
private static final int REQUEST_PERMISSION = 15;
|
||||
|
||||
private static final int DEEPL_TIMEOUT = 20; // seconds
|
||||
private static final String DEEPL_BASE_URI = "https://api-free.deepl.com/v2/";
|
||||
|
||||
private static ExecutorService executor = Helper.getBackgroundExecutor(1, "encrypt");
|
||||
|
||||
|
@ -2016,7 +2017,7 @@ public class FragmentCompose extends FragmentBase {
|
|||
SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(context);
|
||||
String deepl = prefs.getString("deepl", null);
|
||||
|
||||
URL url = new URL("https://api-free.deepl.com/v2/translate?auth_key=" + deepl);
|
||||
URL url = new URL(DEEPL_BASE_URI + "translate?auth_key=" + deepl);
|
||||
HttpsURLConnection connection = (HttpsURLConnection) url.openConnection();
|
||||
connection.setRequestMethod("POST");
|
||||
connection.setDoOutput(true);
|
||||
|
|
Loading…
Reference in a new issue