Class Mongoid::Errors::InvalidOptions
In: lib/mongoid/errors/invalid_options.rb
Parent: MongoidError

Raised when invalid options are passed to a relation macro.

Methods

new  

Public Class methods

Instantiate the options error.

@example Create the error.

  InvalidOptions.new(:name, :polymorphic, [ :as ])

@param [ Symbol ] name The name of the relation. @param [ Symbol ] invalid The invalid option. @param [ Array<Symbol> ] valid The allowed options.

@since 2.1.0

[Validate]