Mercurial > hg > isophonics-drupal-site
comparison vendor/symfony/debug/BufferingLogger.php @ 17:129ea1e6d783
Update, including to Drupal core 8.6.10
author | Chris Cannam |
---|---|
date | Thu, 28 Feb 2019 13:21:36 +0000 |
parents | 4c8ae668cc8c |
children |
comparison
equal
deleted
inserted
replaced
16:c2387f117808 | 17:129ea1e6d783 |
---|---|
18 * | 18 * |
19 * @author Nicolas Grekas <p@tchwork.com> | 19 * @author Nicolas Grekas <p@tchwork.com> |
20 */ | 20 */ |
21 class BufferingLogger extends AbstractLogger | 21 class BufferingLogger extends AbstractLogger |
22 { | 22 { |
23 private $logs = array(); | 23 private $logs = []; |
24 | 24 |
25 public function log($level, $message, array $context = array()) | 25 public function log($level, $message, array $context = []) |
26 { | 26 { |
27 $this->logs[] = array($level, $message, $context); | 27 $this->logs[] = [$level, $message, $context]; |
28 } | 28 } |
29 | 29 |
30 public function cleanLogs() | 30 public function cleanLogs() |
31 { | 31 { |
32 $logs = $this->logs; | 32 $logs = $this->logs; |
33 $this->logs = array(); | 33 $this->logs = []; |
34 | 34 |
35 return $logs; | 35 return $logs; |
36 } | 36 } |
37 } | 37 } |