lib/mongoid.rb in mongoid-7.1.0.rc0 vs lib/mongoid.rb in mongoid-7.1.0

- old
+ new

@@ -1,11 +1,11 @@ # frozen_string_literal: true # encoding: utf-8 require "support/ruby_version" -require "delegate" +require "forwardable" require "time" require "set" require "active_support" require "active_support/core_ext" @@ -34,10 +34,11 @@ # add english load path by default I18n.load_path << File.join(File.dirname(__FILE__), "config", "locales", "en.yml") module Mongoid + extend Forwardable extend Loggable extend self # A string added to the platform details of Ruby driver client handshake documents. # @@ -107,7 +108,7 @@ # # @example Delegate the configuration methods. # Mongoid.database = Mongo::Connection.new.db("test") # # @since 1.0.0 - delegate(*(Config.public_instance_methods(false) - [ :logger=, :logger ] << { to: Config })) + def_delegators Config, *(Config.public_instance_methods(false) - [ :logger=, :logger ]) end