Sha256: b3428c3a30a2266a2b24c94ee8ea9ec0572639b5337ddf872935a7a21786ee25

Contents?: true

Size: 623 Bytes

Versions: 1

Compression:

Stored size: 623 Bytes

Contents

if ActiveRecord::VERSION::MAJOR == 4 && ActiveRecord::VERSION::MINOR <= 0
  # Sometimes for some reason the quoted_table_name  instance methods
  # drops the schema. If the quoted table name does not include a '.'
  # want to retrieve the quoted_table_name from the class and reset
  module ActiveRecord
    # = Active Record Reflection
    module Reflection # :nodoc:
      class AssociationReflection < MacroReflection
        def table_name
          @table_name = klass.table_name
        end

        def quoted_table_name
          @quoted_table_name = klass.quoted_table_name
        end
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
connection_manager-1.0.1 lib/connection_manager/patches/reflections_patch.rb