better ajax error info in debug mode