class Mongoid::Errors::VersioningNotOnRoot

This error is raised when attempting to version an embedded document.

Public Class Methods

new(klass) click to toggle source

Create the new error.

@example Create the new error.

VersioningNotOnRoot.new(Address)

@param [ Class ] klass The embedded class.

@since 3.0.0

Calls superclass method
# File lib/mongoid/errors/versioning_not_on_root.rb, line 15
def initialize(klass)
  super(
    compose_message("versioning_not_on_root", { klass: klass })
  )
end