1
0
mirror of https://github.com/Seldaek/monolog.git synced 2025-10-24 01:56:18 +02:00

Add ability to use formatter in email subject lines

This commit is contained in:
Jordi Boggiano
2016-04-12 18:05:41 +01:00
parent 1fa91efc3b
commit a754edc64c
5 changed files with 63 additions and 1 deletions

View File

@@ -52,4 +52,16 @@ abstract class MailHandler extends AbstractProcessingHandler
{
$this->send((string) $record['formatted'], array($record));
}
protected function getHighestRecord(array $records)
{
$highestRecord = null;
foreach ($records as $record) {
if ($highestRecord === null || $highestRecord['level'] < $record['level']) {
$highestRecord = $record;
}
}
return $highestRecord;
}
}