Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/GeneratorTwigHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,8 @@ public function getHeadPrintCode($title): string

public function getFileLink($path, $text = null, $line = 0): string
{
trigger_deprecation('symfony/maker-bundle', 'v1.53.0', 'getFileLink() is deprecated and will be removed in the future.');

$text = $text ?: $path;

return "<a href=\"{{ '$path'|file_link($line) }}\">$text</a>";
Expand Down
4 changes: 2 additions & 2 deletions src/Resources/skeleton/controller/twig_template.tpl.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@

This friendly message is coming from:
<ul>
<li>Your controller at <code><?= $helper->getFileLink("$root_directory/$controller_path", "$controller_path"); ?></code></li>
<li>Your template at <code><?= $helper->getFileLink("$root_directory/$relative_path", "$relative_path"); ?></code></li>
<li>Your controller at <code><?= $root_directory ?>/<?= $controller_path ?></code></li>
<li>Your template at <code><?= $root_directory ?>/<?= $relative_path ?></code></li>
</ul>
</div>
{% endblock %}