Fixed redirect after post update

This commit is contained in:
2013-01-27 01:12:27 -05:00
parent ee583db78e
commit 89f8e23d92

View File

@@ -35,7 +35,7 @@ class PostsController < ApplicationController
def update def update
if @post.update_attributes(params[:post]) if @post.update_attributes(params[:post])
flash[:notice] = "Post was successfully updated." flash[:notice] = "Post was successfully updated."
redirect_to topic_path(@post.topic) redirect_to topic_path(@post.topic, :page => @post.topic.posts.page.per(10).num_pages, :anchor => @post.id)
end end
end end