Skip to content

Commit

Permalink
Remove nested ternary
Browse files Browse the repository at this point in the history
  • Loading branch information
balping committed Aug 28, 2016
1 parent a4090a3 commit 0e193ea
Showing 1 changed file with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,4 +1,11 @@
{{ ( $greeting !== null ) ? $greeting : ($level == 'error' ? 'Whoops!' : 'Hello!') }}
<?php
if( $greeting !== null ) {
echo e($greeting);
} else {
echo $level == 'error' ? 'Whoops!' : 'Hello!';
}
?>

<?php
Expand Down

0 comments on commit 0e193ea

Please sign in to comment.