fixed bug in post.rb