Skip to content

Commit fee75ad

Browse files
committed
Make use of the nullsafe operator
1 parent 2c2d1fb commit fee75ad

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

Command/LintCommand.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -230,9 +230,7 @@ private function renderException(SymfonyStyle $output, string $template, Error $
230230
{
231231
$line = $exception->getTemplateLine();
232232

233-
if ($githubReporter) {
234-
$githubReporter->error($exception->getRawMessage(), $file, $line <= 0 ? null : $line);
235-
}
233+
$githubReporter?->error($exception->getRawMessage(), $file, $line <= 0 ? null : $line);
236234

237235
if ($file) {
238236
$output->text(sprintf('<error> ERROR </error> in %s (line %s)', $file, $line));

0 commit comments

Comments
 (0)