From 5aea822771c77766f673f8abe4602c3b316d9e8b Mon Sep 17 00:00:00 2001 From: Kamil Kieliszczyk Date: Wed, 12 Mar 2014 10:03:32 +0100 Subject: [PATCH] Update "Has-One Associations" section in README [ci skip] --- README.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/README.md b/README.md index e70c07c5..8881d683 100644 --- a/README.md +++ b/README.md @@ -597,8 +597,14 @@ If you can think of a good way to achieve this, please let me know. PaperTrail can restore `:has_one` associations as they were at (actually, 3 seconds before) the time. ```ruby +class Location < ActiveRecord::Base + belongs_to :treasure + has_paper_trail +end + class Treasure < ActiveRecord::Base has_one :location + has_paper_trail end >> treasure.amount # 100