diff --git a/app/presenters/post_presenter.rb b/app/presenters/post_presenter.rb index 27a881064..d3796013b 100644 --- a/app/presenters/post_presenter.rb +++ b/app/presenters/post_presenter.rb @@ -55,8 +55,8 @@ class PostPresenter < Presenter end if @post.copyright_tags.any? - string << "from" - string << @post.copyright_tags.slice(0, 5).to_sentence + copytags = @post.copyright_tags.slice(0, 5).to_sentence + string << (@post.character_tags.any? ? "(#{copytags})" : copytags) end if @post.artist_tags.any? @@ -64,7 +64,7 @@ class PostPresenter < Presenter string << @post.artist_tags.to_sentence end - string.join(" ").tr("_", " ") + string.empty? ? "##{@post.id}" : string.join(" ").tr("_", " ") end def categorized_tag_string diff --git a/app/views/posts/show.html.erb b/app/views/posts/show.html.erb index 83f4f07f4..ce84e3a7e 100644 --- a/app/views/posts/show.html.erb +++ b/app/views/posts/show.html.erb @@ -95,7 +95,7 @@ <% content_for(:page_title) do %> - <%= @post.presenter.humanized_categorized_tag_string %> - <%= Danbooru.config.app_name %> + <%= @post.presenter.humanized_essential_tag_string %> - <%= Danbooru.config.app_name %> <% end %> <% content_for(:html_header) do %>