Skip to content

Commit

Permalink
Replace deprecated usage of ${} for string interpolation (#1032)
Browse files Browse the repository at this point in the history
Credit to @josephcrowell
  • Loading branch information
josephcrowell authored Jan 9, 2024
1 parent 2d67d42 commit 6bce16c
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions modules/cms/twig/FrameworkNode.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,20 +41,20 @@ public function compile(TwigCompiler $compiler)
$compiler
->write("if (\$_minify) {" . PHP_EOL)
->indent()
->write("echo '<script src=\"${basePath}/modules/system/assets/js/framework.combined-min.js$cacheBust\"></script>'.PHP_EOL;" . PHP_EOL)
->write("echo '<script src=\"{$basePath}/modules/system/assets/js/framework.combined-min.js$cacheBust\"></script>'.PHP_EOL;" . PHP_EOL)
->outdent()
->write("}" . PHP_EOL)
->write("else {" . PHP_EOL)
->indent()
->write("echo '<script src=\"${basePath}/modules/system/assets/js/framework.js$cacheBust\"></script>'.PHP_EOL;" . PHP_EOL)
->write("echo '<script src=\"${basePath}/modules/system/assets/js/framework.extras.js$cacheBust\"></script>'.PHP_EOL;" . PHP_EOL)
->write("echo '<script src=\"{$basePath}/modules/system/assets/js/framework.js$cacheBust\"></script>'.PHP_EOL;" . PHP_EOL)
->write("echo '<script src=\"{$basePath}/modules/system/assets/js/framework.extras.js$cacheBust\"></script>'.PHP_EOL;" . PHP_EOL)
->outdent()
->write("}" . PHP_EOL)
->write("echo '<link rel=\"stylesheet\" property=\"stylesheet\" href=\"${basePath}/modules/system/assets/css/framework.extras'.(\$_minify ? '-min' : '').'.css$cacheBust\">'.PHP_EOL;" . PHP_EOL)
->write("echo '<link rel=\"stylesheet\" property=\"stylesheet\" href=\"{$basePath}/modules/system/assets/css/framework.extras'.(\$_minify ? '-min' : '').'.css$cacheBust\">'.PHP_EOL;" . PHP_EOL)
;
}
else {
$compiler->write("echo '<script src=\"${basePath}/modules/system/assets/js/framework'.(\$_minify ? '-min' : '').'.js$cacheBust\"></script>'.PHP_EOL;" . PHP_EOL);
$compiler->write("echo '<script src=\"{$basePath}/modules/system/assets/js/framework'.(\$_minify ? '-min' : '').'.js$cacheBust\"></script>'.PHP_EOL;" . PHP_EOL);
}

$compiler->write('unset($_minify);' . PHP_EOL);
Expand Down

0 comments on commit 6bce16c

Please sign in to comment.