Refactor duration add subtract duplication