mirror of
https://github.com/jambonz/jambonz-feature-server.git
synced 2025-12-20 16:50:39 +00:00
@@ -1606,15 +1606,15 @@ Duration=${duration} `
|
|||||||
* to be confident we have some time before the say verb is executed, and the Config
|
* to be confident we have some time before the say verb is executed, and the Config
|
||||||
* does not give us that confidence since it returns immediately.
|
* does not give us that confidence since it returns immediately.
|
||||||
*/
|
*/
|
||||||
const allTasks = (this.tasks || []).concat(newTasks);
|
const haveQueuedNonConfig = this.tasks.findIndex((t) => t.name !== TaskName.Config) !== -1;
|
||||||
const skipFirst = allTasks.slice(1);
|
let tasks = haveQueuedNonConfig ? newTasks : [];
|
||||||
const idxFirstNotConfig = skipFirst.findIndex((t) => t.name !== TaskName.Config);
|
if (!haveQueuedNonConfig) {
|
||||||
if (-1 === idxFirstNotConfig) return;
|
const idxFirstNotConfig = newTasks.findIndex((t) => t.name !== TaskName.Config);
|
||||||
|
if (-1 === idxFirstNotConfig) return;
|
||||||
|
tasks = newTasks.slice(idxFirstNotConfig + 1);
|
||||||
|
}
|
||||||
|
|
||||||
const allTasksAfterFirstNotConfig = skipFirst.slice(idxFirstNotConfig);
|
for (const task of tasks) {
|
||||||
|
|
||||||
|
|
||||||
for (const task of allTasksAfterFirstNotConfig) {
|
|
||||||
if (task.name === TaskName.Config && task.hasSynthesizer) {
|
if (task.name === TaskName.Config && task.hasSynthesizer) {
|
||||||
/* if they change synthesizer settings don't try to precache */
|
/* if they change synthesizer settings don't try to precache */
|
||||||
break;
|
break;
|
||||||
|
|||||||
Reference in New Issue
Block a user