Created
February 11, 2009 01:27
-
-
Save nitsujw/61753 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@posts = @topic.posts.paginate(:per_page => 25, :page => params[:page], :order => [:created_at.asc]) # Runs an update on posts | |
@posts = Post.paginate(:per_page => 25, :page => params[:page], :order => [:created_at.asc], :topic_id => @topic.id) # Doesn't run an update on posts | |
## The first line above calls this on the show action, when it should only run before saving an object | |
before :save, :white_list |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment