diff options
author | Rémy Coutable <remy@rymai.me> | 2016-07-21 13:18:34 +0300 |
---|---|---|
committer | Rémy Coutable <remy@rymai.me> | 2016-07-21 13:18:34 +0300 |
commit | 71a3336dc4f241e00c006a222397e62b039672ed (patch) | |
tree | 48d87e0f5c72ef9bfaa23d6dc2615e2b425fcb40 /app/helpers/time_helper.rb | |
parent | 479814b29289ab5598117ff22b63e386a3d2d9f3 (diff) |
Cast duration to integer in `TimeHelper#time_interval_in_words`
Signed-off-by: Rémy Coutable <remy@rymai.me>
Diffstat (limited to 'app/helpers/time_helper.rb')
-rw-r--r-- | app/helpers/time_helper.rb | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/app/helpers/time_helper.rb b/app/helpers/time_helper.rb index 1926f03af07..790001222f1 100644 --- a/app/helpers/time_helper.rb +++ b/app/helpers/time_helper.rb @@ -1,5 +1,6 @@ module TimeHelper def time_interval_in_words(interval_in_seconds) + interval_in_seconds = interval_in_seconds.to_i minutes = interval_in_seconds / 60 seconds = interval_in_seconds - minutes * 60 |