8000 Throw an exception on error, introduce error domains to handle them safely by adamziel · Pull Request #124 · WordPress/php-toolkit · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Throw an exception on error, introduce error domains to handle them safely #124

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

Closed
wants to merge 1 commit into from

Conversation

adamziel
Copy link
Collaborator
@adamziel adamziel commented Jan 9, 2025

Managing errors via a cascade of return false and get_error_info() is cumbersome and error-prone. This PR proposes migrating that to Exceptions. To avoid crashing applications with uncaught exceptions, it also drafts an error domain clas that could wrap all the registered hooks and filters.

WIP.

cc @dmsnell

@adamziel adamziel closed this May 30, 2025
@github-project-automation github-project-automation bot moved this from Inbox to Done in Playground Board May 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Archived in project
Development

Successfully merging this pull request may close these issues.

1 participant
0