Details
-
Type:
Bug
-
Status: Open
-
Priority:
Major
-
Resolution: Unresolved
-
Affects Version/s: None
-
Fix Version/s: None
-
Component/s: None
-
Labels:None
Description
This issue needs to be duplicated first.
A less-practical example would require editing an existing AJAX request.
Consider the edit service page in the admin UI. This page makes an AJAX request to display the totals in a box.
If the GET parameters for this request do not include both a valid client and service ID, or the service does not match the client, a 401 response is encountered.
Currently, a 401 response will cause the edit-service page to refresh continuously because it will continuously make the same invalid AJAX request.
If a 401 response did not perform a redirect, the UI would not be updated to include the totals box.
On a side note, the JS also performs an identical redirect for status code 406.
// If an ajax request was attempted, but the resource does not support it, reload if (request.status == 406) { window.location = window.location.href; }