Commit ba58281d authored by Michal Čihař's avatar Michal Čihař

Detect errors from machine translation (issue #179)

parent eac7147d
......@@ -70,7 +70,11 @@ function process_mt(data, textStatus, jqXHR) {
if (typeof(data.responseData) == 'undefined') {
mt_set(data);
} else if (data.responseData != '') {
mt_set(data.responseData.translatedText);
if (data.responseStatus == 200) {
mt_set(data.responseData.translatedText);
} else {
failed_mt(null, data.responseDetails, null)
}
}
dec_loading();
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment