From 660b17ba34a19b7e1f6754dd8d9bc927ce7f4f4d Mon Sep 17 00:00:00 2001 From: Fang Date: Sat, 12 Aug 2017 13:03:58 -0700 Subject: [PATCH] Fixed rendered of %app and %lin speeches in %fat. --- web/talk/main.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/web/talk/main.js b/web/talk/main.js index eaeca6d6c7..5fa3275d3a 100644 --- a/web/talk/main.js +++ b/web/talk/main.js @@ -778,7 +778,10 @@ module.exports = recl({ case speech.url == null: return speechArr = speech.url.txt.split(/(\s|-)/); case speech.fat == null: - return speech.fat.taf.exp.txt.split(/(\s|-)/); + if (typeof speech.fat.taf.exp !== 'undefined') { return speech.fat.taf.exp.txt.split(/(\s|-)/); } + if (typeof speech.fat.taf.app !== 'undefined') { return speech.fat.taf.app.txt; } + if (typeof speech.fat.taf.lin !== 'undefined') { return speech.fat.taf.lin.txt; } + return "unsupported fat speech"; default: return []; }