Skip to content

Commit

Permalink
CoreMacros: {dump} updated for 2.3
Browse files Browse the repository at this point in the history
  • Loading branch information
dg committed Mar 27, 2015
1 parent 0cede35 commit 0aa565b
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/Latte/Macros/CoreMacros.php
Original file line number Diff line number Diff line change
Expand Up @@ -306,8 +306,10 @@ public function macroAttr(MacroNode $node, PhpWriter $writer)
public function macroDump(MacroNode $node, PhpWriter $writer)
{
$args = $writer->formatArgs();
return 'Tracy\Debugger::barDump(' . ($node->args ? $writer->write("array(%var => $args)", $args) : 'get_defined_vars()')
. ', "Template " . str_replace(dirname(dirname($template->getName())), "\xE2\x80\xA6", $template->getName()))';
return $writer->write(
'Tracy\Debugger::barDump(' . ($args ? "($args)" : 'get_defined_vars()'). ', %var)',
$args ?: 'variables'
);
}


Expand Down

0 comments on commit 0aa565b

Please sign in to comment.