Commit Graph

5 Commits

Author SHA1 Message Date
Javi Martín
d0d681a44b Add and apply EmptyLineAfterGuardClause rule
We were inconsistent on this one. I consider it particularly useful when
a method starts with a `return` statement.

In other cases, we probably shouldn't have a guard rule in the middle of
a method in any case, but that's a different refactoring.
2019-10-24 17:56:03 +02:00
Bertocq
b79df113cd Switch all Time.curren.to_date for Date.current, same result but better syntax 2017-06-11 10:41:09 +02:00
Bertocq
02524b164a Rubocop autocorrections (indentations, revers unless to if, extra spaces) 2017-06-08 12:14:35 +02:00
Bertocq
9e74249b02 Always use Time.current (aliases internally to Time.zone.now)
Some specs where breaking close to midnight because 30.years.ago uses zone.now and Time.now.utc.to_date doesn't.
Also this will make all codebase consistent in the way time is deal with
2017-05-24 07:54:57 +02:00
kikito
ba87eaa47c Moves Age calculation to a module instead of monkeypatching Date 2017-02-03 15:35:41 +01:00