-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Ajax code #976
Ajax code #976
Conversation
so we can examine the error code if necessary. Add a function ajaxAlert() to alert with the error message.
Sandbox at: https://www.pgdp.org/~rp31/c.branch/ajax_code The only place this could have any effect so far as I can tell is the page browser where selecting an invalid project id or non-existent page will give an alert message. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Returning the full error block to the client makes sense. I'm a little wary of the convention of having the client alert()
the error to the user. That means we need to design error messages for the end user, not the client developer.
Note: we should squash these commits on merge. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bearing in mind that I know absolutely nothing about ajax, and that the code means nothing to me, I tested the page browser with invalid, nonexistent and archived projects, and with a nonexistent page number, comparing TEST with the branch, and didn't see any discrepancies.
I do think the |
Sandbox updated with latest changes. |
Let ajax function return all data on not ok
so we can examine the error code if necessary.
Add a function ajaxAlert() to alert with the error message.