[COMPONENTS][Attachment] Fixed typo on attachmentShowWithNote, where the template called was somehow replaced with a child of it

This commit is contained in:
Eliseu Amaro 2022-01-18 00:58:25 +00:00 committed by Hugo Sales
parent 6ab740d780
commit c4f9e58e8d
No known key found for this signature in database
GPG Key ID: 7D0C7EAFC9D835A0
2 changed files with 1 additions and 4 deletions

View File

@ -89,7 +89,7 @@ class Attachment extends Controller
try {
return $this->attachment($attachment_id, $note_id, function ($res) use ($note_id, $attachment_id) {
return [
'_template' => '/cards/attachments/view.html.twig',
'_template' => '/cards/attachments/show.html.twig',
'download' => $res['attachment']->getDownloadUrl(note: $note_id),
'title' => $res['title'],
'attachment' => $res['attachment'],

View File

@ -3,11 +3,8 @@
{% block body %}
<div class="page">
<section class="section-widget section-padding">
{% include '/cards/attachments/view.html.twig' with {'attachment': attachment, 'note': note, 'title': title} only %}
<a class="section-widget-button-like" href="{{ download }}"> {{ 'Download link' | trans }}</a>
</section>
</div>
{% endblock body %}