Sha256: 60376e62b526a3a802cde7404cd5fc0c18f94319af0f1790de04da8d9494cc97

Contents?: true

Size: 466 Bytes

Versions: 4

Compression:

Stored size: 466 Bytes

Contents

# frozen_string_literal: true

module ActiveFields
  module Field
    # If the field base class has been changed, we should prevent this model from being loaded.
    # Since we cannot remove it entirely, we will not add any functionality to it.
    if ActiveFields.config.field_base_class_changed?
      class Base; end
    else
      class Base < ApplicationRecord
        self.table_name = "active_fields"

        include FieldConcern
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
active_fields-2.0.0 app/models/active_fields/field/base.rb
active_fields-1.1.0 app/models/active_fields/field/base.rb
active_fields-1.0.0 app/models/active_fields/field/base.rb
active_fields-0.2.0 app/models/active_fields/field/base.rb