Skip to content
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

Enable JsonResponseHandler for Whoops! to send JSON formatted errors for AJAX requests #2433

Merged
merged 2 commits into from
Jan 10, 2015
Merged

Enable JsonResponseHandler for Whoops! to send JSON formatted errors for AJAX requests #2433

merged 2 commits into from
Jan 10, 2015

Conversation

GwendolenLynch
Copy link
Contributor

An example of what is given in error generating AJAX requests now:

{
    "error" : {
        "type" : "UnexpectedBeerException",
        "message" : "Expected more beer in request. Unable to continue!",
        "file" : "src/Application.php",
        "line" : 123
    }
}

NOTE This attaches to the Whoops! service provider, so will only be sent in the cases where a HTML Whoops! otherwise would.

Changelog

  • Whoops now sends errors to AJAX callers in JSON format

@GwendolenLynch
Copy link
Contributor Author

Hold this... Might need to tweak.

@GwendolenLynch
Copy link
Contributor Author

OK, good to go... Once Travis agrees!

@bobdenotter
Copy link
Member

A'ight!

bobdenotter added a commit that referenced this pull request Jan 10, 2015
Enable JsonResponseHandler for Whoops! to send JSON formatted errors for AJAX requests
@bobdenotter bobdenotter merged commit 23da146 into bolt:master Jan 10, 2015
@GwendolenLynch GwendolenLynch deleted the feature/ajax-handler-whoops branch January 10, 2015 11:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants