]> _ Git - cubeextranet.git/commitdiff
wait #5784 @0:20
authorvincent@cubedesigners.com <vincent@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Tue, 7 Mar 2023 15:56:48 +0000 (15:56 +0000)
committervincent@cubedesigners.com <vincent@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Tue, 7 Mar 2023 15:56:48 +0000 (15:56 +0000)
inc/ws/Util/html5/master/class.ws.html5.compiler.php

index 327820c94d502b3565d73066af6265f199a036be..8aac88c5e1c9c0fa591c0f76cac4a24767a5c1f9 100644 (file)
@@ -1517,7 +1517,7 @@ height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
             $text = str_replace(array_keys($replace), array_values($replace), $text);
             $text = CubeIT_Text::cleanUTF8($text, '');
 
-            $voiceInfos = $data['voice'] ?: $this->book->parametres->audiodescriptionVoice;
+            $voiceInfos = $data['voice'] ?? $this->book->parametres->audiodescriptionVoice;
 
             if ($voiceInfos) {
                 $hash = hash('sha256', $voiceInfos . '_^_' . $text);
@@ -1579,7 +1579,7 @@ height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
             $api = new \Cubist\Azure\TTS\Api('28fdfcdcc7f141b29cd9db4afc5779c5');
             $api->textToSpeech($text, $locale, $gender, $voiceName, $output);
         } catch (Exception $e) {
-            dd($e);
+
         }
     }
 
@@ -2659,10 +2659,10 @@ height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
         if ($ext === 'txt') {
             $file = $this->wdir . '/' . $link['to'];
             if (file_exists($file)) {
-                $this->audioDescriptionTextsList[$link['page']] = file_get_contents($file);
+                $this->audioDescriptionTextsList[$link['page']] = ['text' => file_get_contents($file)];
             }
         } else {
-            $this->config->audiodescription[$link['page']] = $link['to'];
+            $this->config->audiodescription[$link['page']] = ['text' => $link['to']];
             $this->copyLinkFile($link['to'], 'data/audiodescription/');
         }
     }
@@ -3658,7 +3658,7 @@ height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
             }
         }
 
-        $res=['dir' => $dir, 'fdir' => $fdir];
+        $res = ['dir' => $dir, 'fdir' => $fdir];
         return $res;
     }