mirror of
https://github.com/Seldaek/monolog.git
synced 2026-04-25 23:55:56 +03:00
[PR #646] [CLOSED] Prevent HipChat API failure from throwing an exception #1275
Labels
No labels
Bug
Documentation
Feature
Needs Work
Support
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/monolog#1275
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Seldaek/monolog/pull/646
Author: @alextartan
Created: 9/16/2015
Status: ❌ Closed
Base:
master← Head:master📝 Commits (2)
bea629eUpdate HipChatHandler.phpcfa4b33Merge pull request #1 from alextartan/alextartan-patch-hipchat-write📊 Changes
1 file changed (+6 additions, -2 deletions)
View changed files
📝
src/Monolog/Handler/HipChatHandler.php(+6 -2)📄 Description
When a connection to HipChat API cannot be established, the 'createSocketResource' method from the 'SocketHandler' class throws an exception.
To prevent this, I've wrapped the "write" method from the 'HipChatHandler' class in a try-catch block. While the call specifically throws an 'UnexpectedValueException', the catch is using '\Exception' since no action is actually needed and the exception type doesn't really matter is this particular case.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.