Sha256: 00b4c6f8a4a05becb0b24d2529dc9f4307a0b1481a01ca0741975b21c9b435d3

Contents?: true

Size: 638 Bytes

Versions: 15

Compression:

Stored size: 638 Bytes

Contents

# frozen_string_literal: true

module Mongoid
  module Errors

    # This error is raised when a client is configured without a database.
    class NoClientDatabase < MongoidError

      # Create the new error.
      #
      # @example Create the new error.
      #   NoClientDatabase.new(:default, {}})
      #
      # @param [ Symbol | String ] name The db config key.
      # @param [ Hash ] config The hash configuration options.
      def initialize(name, config)
        super(
          compose_message(
            "no_client_database",
            { name: name, config: config }
          )
        )
      end
    end
  end
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
mongoid-8.1.7 lib/mongoid/errors/no_client_database.rb
mongoid-8.1.6 lib/mongoid/errors/no_client_database.rb
mongoid-8.0.8 lib/mongoid/errors/no_client_database.rb
mongoid-8.1.5 lib/mongoid/errors/no_client_database.rb
mongoid-8.1.4 lib/mongoid/errors/no_client_database.rb
mongoid-8.0.7 lib/mongoid/errors/no_client_database.rb
mongoid-8.1.3 lib/mongoid/errors/no_client_database.rb
mongoid-8.1.2 lib/mongoid/errors/no_client_database.rb
mongoid-8.0.6 lib/mongoid/errors/no_client_database.rb
mongoid-8.1.1 lib/mongoid/errors/no_client_database.rb
mongoid-8.0.5 lib/mongoid/errors/no_client_database.rb
mongoid-8.1.0 lib/mongoid/errors/no_client_database.rb
mongoid-8.0.4 lib/mongoid/errors/no_client_database.rb
mongoid-8.0.3 lib/mongoid/errors/no_client_database.rb
mongoid-8.0.2 lib/mongoid/errors/no_client_database.rb