mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Switch to short array syntax in DetailedErrorFormatter, add spaces between array values
This commit is contained in:
parent
e211e27470
commit
73df3166b7
@ -25,7 +25,7 @@ class DetailedErrorFormatter implements FormatterInterface
|
||||
);
|
||||
} else {
|
||||
$context = isset($record['context']) ? $record['context'] : $record;
|
||||
foreach (array('code','message','file','line') as $key) {
|
||||
foreach (['code', 'message', 'file', 'line'] as $key) {
|
||||
if (!isset($context[$key])) {
|
||||
$context[$key] = isset($record[$key]) ? $record[$key] : null;
|
||||
}
|
||||
@ -57,7 +57,7 @@ class DetailedErrorFormatter implements FormatterInterface
|
||||
|
||||
public function formatBatch(array $records)
|
||||
{
|
||||
return implode("\n", array_map(array($this, 'format'), $records));
|
||||
return implode("\n", array_map([$this, 'format'], $records));
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user