Fix example code in doc/general/getting_started.md

The `belongs_to` method should take relation name, not a foreign_key property.
This commit is contained in:
Ryunosuke Sato 2017-03-24 10:40:27 +09:00
parent 80e470dcdb
commit cec6478f32

View File

@ -37,7 +37,7 @@ and
class CommentSerializer < ActiveModel::Serializer class CommentSerializer < ActiveModel::Serializer
attributes :name, :body attributes :name, :body
belongs_to :post_id belongs_to :post
end end
``` ```