mirror of
https://github.com/Seldaek/monolog.git
synced 2025-08-08 06:06:40 +02:00
Trying to carefully improve the language on a common exception message
For example, if using Symfony, this is probably that first thing you'll see after installing, because the logs directory won't be writable. So, ideally, it should be clear enough that the user knows to change the permissions on the directory. Many developers might not understand the idea of a "stream", but they do understand a file not being writable.
This commit is contained in:
@@ -64,7 +64,7 @@ class StreamHandler extends AbstractProcessingHandler
|
||||
$this->stream = @fopen($this->url, 'a');
|
||||
if (!is_resource($this->stream)) {
|
||||
$this->stream = null;
|
||||
throw new \UnexpectedValueException('The stream could not be opened, "'.$this->url.'" may be an invalid url.');
|
||||
throw new \UnexpectedValueException(sprintf('The stream or file "%s" could not be opened; it may be invalid or not writable.', $this->url));
|
||||
}
|
||||
}
|
||||
fwrite($this->stream, (string) $record['message']);
|
||||
|
Reference in New Issue
Block a user