forum fixes

This commit is contained in:
albert
2013-02-19 12:31:25 -05:00
parent e0fdda3103
commit fd14dfb7b5
2 changed files with 6 additions and 2 deletions

View File

@@ -26,7 +26,11 @@ class ForumPostsController < ApplicationController
def show
@forum_post = ForumPost.find(params[:id])
respond_with(@forum_post)
if request.format == "text/html" && @forum_post.id == @forum_post.topic.original_post.id
redirect_to(forum_topic_path(@forum_post.topic))
else
respond_with(@forum_post)
end
end
def create

View File

@@ -25,7 +25,7 @@
<%= link_to topic.title, forum_topic_path(topic) %>
<% if topic.response_count > 30 %>
<% if topic.response_count > Danbooru.config.posts_per_page %>
<%= link_to "last", forum_topic_path(topic, :page => topic.last_page), :class => "last-page" %>
<% end %>