Bläddra i källkod

fix: Skips setting language for transcriptions if not enabled.

master
Дамян Минков 4 år sedan
förälder
incheckning
576fd0d343
1 ändrade filer med 6 tillägg och 1 borttagningar
  1. 6
    1
      react/features/transcribing/functions.js

+ 6
- 1
react/features/transcribing/functions.js Visa fil

15
  * @returns {string}
15
  * @returns {string}
16
  */
16
  */
17
 export function determineTranscriptionLanguage(config: Object) {
17
 export function determineTranscriptionLanguage(config: Object) {
18
-    const { preferredTranscribeLanguage, transcribeWithAppLanguage = true } = config;
18
+    const { preferredTranscribeLanguage, transcribeWithAppLanguage = true, transcribingEnabled } = config;
19
+
20
+    // if transcriptions are not enabled nothing to determine
21
+    if (!transcribingEnabled) {
22
+        return undefined;
23
+    }
19
 
24
 
20
     // Depending on the config either use the language that the app automatically detected or the hardcoded
25
     // Depending on the config either use the language that the app automatically detected or the hardcoded
21
     // config BCP47 value.
26
     // config BCP47 value.

Laddar…
Avbryt
Spara