Skip to content

Commit

Permalink
MacroBlockVariable made non-greedy
Browse files Browse the repository at this point in the history
  • Loading branch information
paveljanda committed Feb 27, 2018
1 parent ad10720 commit 6f68d79
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Markdown/Macros/MacroBlockVariable.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ protected function runVariableMacro(string & $content): void // Intentionally &
* Remove lines with inline variables definition and put then into DocuScope
*/
$content = preg_replace_callback(
'/^\$\$([a-zA-Z_0-9]+)\n(.+)\$\$$/ms',
'/^\$\$([a-zA-Z_0-9]+)\n(.+?)\$\$$/ms',
function(array $input): string {
$this->docuScope->addBlockVariable($input[1], $input[2]);

Expand Down

0 comments on commit 6f68d79

Please sign in to comment.