class ActiveSupport::Duration::Scalar

def -(other)

def -(other)
  if Duration === other
    seconds   = value - other._parts.fetch(:seconds, 0)
    new_parts = other._parts.transform_values(&:-@)
    new_parts = new_parts.merge(seconds: seconds)
    new_value = value - other.value
    Duration.new(new_value, new_parts, other.variable?)
  else
    calculate(:-, other)
  end
end