Created
November 12, 2008 23:40
Revisions
-
nitsujw revised this gist
Nov 12, 2008 . 1 changed file with 10 additions and 0 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -2,4 +2,14 @@ @post = Post.get(id) raise NotFound unless @post display @post end def create(comment) @comment = Comment.new(comment) if @comment.save eager_cache([Posts, :show], :store => :action_store) { self.class.build_request(url(:post, @comment.post)) } partial 'comments/comment', :comment => @comment else return "Error saving comment" end end -
nitsujw created this gist
Nov 12, 2008 .There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,5 @@ def show(id) @post = Post.get(id) raise NotFound unless @post display @post end