mirror of
https://github.com/Seldaek/monolog.git
synced 2025-10-24 10:06:08 +02:00
Add constructor injection for SocketHandler and its children (#1600)
* feature: add constructor injection for `SocketHandler` and its children Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com> * docs: add parameter documentation to `SocketHandler#__construct` Signed-off-by: Maximilian Bösing <2189546+boesing@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
d1c2829268
commit
4a11cadb27
@@ -59,13 +59,27 @@ class SlackHandler extends SocketHandler
|
||||
bool $bubble = true,
|
||||
bool $useShortAttachment = false,
|
||||
bool $includeContextAndExtra = false,
|
||||
array $excludeFields = array()
|
||||
array $excludeFields = array(),
|
||||
bool $persistent = false,
|
||||
float $timeout = 0.0,
|
||||
float $writingTimeout = 10.0,
|
||||
?float $connectionTimeout = null,
|
||||
?int $chunkSize = null
|
||||
) {
|
||||
if (!extension_loaded('openssl')) {
|
||||
throw new MissingExtensionException('The OpenSSL PHP extension is required to use the SlackHandler');
|
||||
}
|
||||
|
||||
parent::__construct('ssl://slack.com:443', $level, $bubble);
|
||||
parent::__construct(
|
||||
'ssl://slack.com:443',
|
||||
$level,
|
||||
$bubble,
|
||||
$persistent,
|
||||
$timeout,
|
||||
$writingTimeout,
|
||||
$connectionTimeout,
|
||||
$chunkSize
|
||||
);
|
||||
|
||||
$this->slackRecord = new SlackRecord(
|
||||
$channel,
|
||||
|
||||
Reference in New Issue
Block a user