Sha256: 6b7a92fdde9e2c354b67344981ac47c66910f0901853d9d141dda169ee685a30

Contents?: true

Size: 561 Bytes

Versions: 105

Compression:

Stored size: 561 Bytes

Contents

# encoding: utf-8
module Mongoid
  module Errors

    # This exception is raised when a bad value is attempted to be converted to
    # a date or time.
    class InvalidTime < MongoidError

      # Create the new invalid date error.
      #
      # @example Create the new invalid date error.
      #   InvalidTime.new("this is not a time")
      #
      # @param [ Object ] value The value that was attempted.
      #
      # @since 2.3.1
      def initialize(value)
        super(compose_message("invalid_time", { value: value }))
      end
    end
  end
end

Version data entries

105 entries across 100 versions & 7 rubygems

Version Path
mongoid-7.0.13 lib/mongoid/errors/invalid_time.rb
mongoid-7.0.12 lib/mongoid/errors/invalid_time.rb
mongoid-6.4.8 lib/mongoid/errors/invalid_time.rb
mongoid-7.0.11 lib/mongoid/errors/invalid_time.rb
mongoid-7.0.10 lib/mongoid/errors/invalid_time.rb
mongoid-6.4.7 lib/mongoid/errors/invalid_time.rb
mongoid-6.4.5 lib/mongoid/errors/invalid_time.rb
mongoid-7.0.8 lib/mongoid/errors/invalid_time.rb
mongoid-7.0.7 lib/mongoid/errors/invalid_time.rb
mongoid-7.0.6 lib/mongoid/errors/invalid_time.rb
mongoid-5.4.1 lib/mongoid/errors/invalid_time.rb
mongoid-7.0.5 lib/mongoid/errors/invalid_time.rb
mongoid-7.0.4 lib/mongoid/errors/invalid_time.rb
mongoid-6.4.4 lib/mongoid/errors/invalid_time.rb
mongoid-7.0.3 lib/mongoid/errors/invalid_time.rb
mongoid-6.4.2 lib/mongoid/errors/invalid_time.rb
mongoid-7.0.2 lib/mongoid/errors/invalid_time.rb
mongoid-7.0.1 lib/mongoid/errors/invalid_time.rb
mongoid-6.4.1 lib/mongoid/errors/invalid_time.rb
mongoid-5.4.0 lib/mongoid/errors/invalid_time.rb