gfse: bug fix: syntax check in concrete syntax wasn't working

In newer versions of GF the shell says "syntax error" instead of "parse error".
This commit is contained in:
hallgren
2012-02-10 13:38:24 +00:00
parent 9dfab3d187
commit d8958ed68d
2 changed files with 2 additions and 2 deletions

View File

@@ -140,7 +140,7 @@ function gfshell(cmd,cont) {
function check_exp(s,cont) {
function check(gf_message) {
//debug("cc "+s+" = "+gf_message);
cont(/parse error/.test(gf_message) ? "parse error" : null);
cont(/(parse|syntax) error/.test(gf_message) ? "syntax error" : null);
}
if(navigator.onLine)
ajax_http_get("upload.cgi?cc="+encodeURIComponent(s),check)

View File

@@ -171,7 +171,7 @@ function gfshell(cmd,cont) {
function check_exp(s,cont) {
function check(gf_message) {
//debug("cc "+s+" = "+gf_message);
cont(/parse error/.test(gf_message) ? "parse error" : null);
cont(/(parse|syntax) error/.test(gf_message) ? "syntax error" : null);
}
gfshell("cc "+s,check);
}