summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/GF/Speech/GrammarToVoiceXML.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/GF/Speech/GrammarToVoiceXML.hs b/src/GF/Speech/GrammarToVoiceXML.hs
index 5fbef29b6..7b27e9f34 100644
--- a/src/GF/Speech/GrammarToVoiceXML.hs
+++ b/src/GF/Speech/GrammarToVoiceXML.hs
@@ -171,7 +171,7 @@ fun2sub gr cat fun args =
doCallback :: String -> VIdent -> [XML] -> [XML] -> XML
doCallback f cat i e =
- if_else ("callbacks && " ++ cf ++ " && !" ++ cf ++ "("++string (prIdent cat)++","++ catFieldId cat ++ ")")
+ if_else ("typeof callbacks != 'undefined' && typeof " ++ cf ++ " != 'undefined' && !" ++ cf ++ "("++string (prIdent cat)++","++ catFieldId cat ++ ")")
i e
where cf = "callbacks." ++ f