neos-ui
                                
                                 neos-ui copied to clipboard
                                
                                    neos-ui copied to clipboard
                            
                            
                            
                        Bug/Improvement: Fetch-with-error-handling should get json from Flows error-handler
When there is an exception in a Ui ajax request, Flows error-handler doesnt respect the accept header, and we dont set it.
Accept: application/json
For better display and further handling, we need errors in the json format.
Maybe the proposed header Accept: application/json is not always correct, as i know of some cases where we fetch xml from the server, for example in the link editor.
Currently, the "fetchWithErrorHandling" helper tries to put the Html from the Flow exception-handler into a temporary dom element to retrieve the innerText and tries to display the headline or something, but this is rather suboptimal and not always working correctly.
This is the respective ancient flow issue :D https://github.com/neos/flow-development-collection/issues/550