Sha256: 4fe6bf8ac6ffdddcf394e4ae5f4582b85cd8bd83e0aa05fb195c1e5552485112
Contents?: true
Size: 785 Bytes
Versions: 29
Compression:
Stored size: 785 Bytes
Contents
# frozen_string_literal: true module Mongoid module Errors # Raised when no inverse_of definition can be found when needed. class InverseNotFound < MongoidError # Create then new error. # # @example Create the new error. # InverseNotFound.new(Town, :citizens, Person, :town_id) # # @param [ Class ] base The base class. # @param [ Symbol ] name The name of the association. # @param [ Class ] klass The child class. # @param [ Symbol ] inverse The attempted inverse key. def initialize(base, name, klass, inverse) super( compose_message( "inverse_not_found", { base: base, name: name, klass: klass, inverse: inverse } ) ) end end end end
Version data entries
29 entries across 29 versions & 1 rubygems