Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
easier way to subtract a duration from a time
previous behaviour resulted in same as addition: ```ruby Fugit.parse('1Y') + Time.parse("2023-01-19T12:07:00T") # => 2024-01-19T12:07:00T Fugit.parse('1Y') - Time.parse("2023-01-19T12:07:00T") # => 2024-01-19T12:07:00T ``` With this change, the duration is now subtracted from the time: ```ruby Fugit.parse('1Y') + Time.parse("2023-01-19T12:07:00T") # => 2024-01-19T12:07:00T Fugit.parse('1Y') - Time.parse("2023-01-19T12:07:00T") # => 2022-01-19T12:07:00T ``` Mathematically this isn't quite correct I suppose, but neither is the current behaviour.
- Loading branch information