onimamy / tinycimm

Automatically exported from code.google.com/p/tinycimm
0 stars 0 forks source link

Find a better way of return json results #8

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
I don't like the way that json arrays are managed on both the front and
backend. 
I think simply a change to using boolean types instead of string 'error' or
'success' will have to do for now, it's definitely a lot more elegant.

JS EG:

var obj = tinymce.util.JSON.parse(response);
if (!obj.outcome) {
  tinyMCEPopup.editor.windowManager.alert(obj.message);
} else {
  ...
}

Original issue reported on code.google.com by willis...@gmail.com on 5 May 2009 at 2:58

GoogleCodeExporter commented 8 years ago
done

Original comment by willis...@gmail.com on 6 May 2009 at 12:36