From a451ad159c704783060866351a86848dfb5ff8ad Mon Sep 17 00:00:00 2001 From: Takumasa Ochi Date: Wed, 6 Sep 2023 18:03:59 +0900 Subject: [PATCH] Use actually defined methods, `since` and `ago` --- README.adoc | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.adoc b/README.adoc index cccc0e4..49b3fe1 100644 --- a/README.adoc +++ b/README.adoc @@ -1865,12 +1865,12 @@ Use an instance of `ActiveSupport::Duration` as a receiver to calculate relative [source,ruby] ---- # bad - It's confusing to read -created_at.after(1.minute) -expiration_date.before(3.days) +created_at.since(1.minute) +expiration_date.ago(3.days) # good -1.minute.after(created_at) -3.days.before(expiration_date) +1.minute.since(created_at) +3.days.ago(expiration_date) ---- == Bundler