diff --git a/app/views/decidim/blogs/posts/show.html.erb b/app/views/decidim/blogs/posts/show.html.erb index 6dbcb9423..1d5831dc8 100644 --- a/app/views/decidim/blogs/posts/show.html.erb +++ b/app/views/decidim/blogs/posts/show.html.erb @@ -5,6 +5,7 @@ description: translated_attribute(post.body).truncate(Rails.application.config.default_blog_ogp_description_limit), url: post_url(post.id) }) %> + <% doc = Nokogiri::HTML(translated_attribute(post.body)) img = doc.css('img')&.first @@ -27,7 +28,9 @@ <% end %>

<%= translated_attribute post.title %>

- <%= cell "decidim/author", present(post.author), from: post %> + + <% post_presenter = Decidim::Blogs::PostPresenter.new(post) %> + <%= cell "decidim/author", post_presenter.author, from: post %>
<% if show_endorsements_card? %> @@ -54,10 +57,11 @@ <% end %>
">
- <%= decidim_sanitize_editor translated_attribute post.body %> + <%= decidim_sanitize_editor_admin translated_attribute(post.body) %>
<%= cell "decidim/endorsers_list", post %>
<%= attachments_for post %> <%= comments_for post %> +<%= cell("decidim/flag_modal", post) %>