Sha256: 9e71026abd0375e4211cc4173721dfeb0a841e0491f68fca3dae9cae7cdbdb22

Contents?: true

Size: 387 Bytes

Versions: 100

Compression:

Stored size: 387 Bytes

Contents

# Temporary fix to FriendlyId in Rails5, so that we don't
# encounter any validation errors when creating slugs via
# FriendlyId::History on a paranoid model.
# See: https://github.com/norman/friendly_id/issues/822
if Rails::VERSION::STRING >= '5.0'
  module FriendlyId
    class Slug < ActiveRecord::Base
      belongs_to :sluggable, polymorphic: true, optional: true
    end
  end
end

Version data entries

100 entries across 100 versions & 2 rubygems

Version Path
spree_core-3.7.10 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.0.3 lib/friendly_id/slug_rails5_patch.rb
spree_core-3.7.9 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.0.2 lib/friendly_id/slug_rails5_patch.rb
spree_core-3.7.8 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.0.1 lib/friendly_id/slug_rails5_patch.rb
spree_core-3.7.7 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.0.0 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.0.0.rc3 lib/friendly_id/slug_rails5_patch.rb
spree_core-3.7.6 lib/friendly_id/slug_rails5_patch.rb
spree_core-3.7.5 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.0.0.rc2 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.0.0.rc1 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.0.0.beta lib/friendly_id/slug_rails5_patch.rb
spree_core-3.7.4 lib/friendly_id/slug_rails5_patch.rb
spree_core-3.7.3 lib/friendly_id/slug_rails5_patch.rb
spree_core-3.7.2 lib/friendly_id/slug_rails5_patch.rb
spree_core-3.7.1 lib/friendly_id/slug_rails5_patch.rb
spree_core-3.7.0 lib/friendly_id/slug_rails5_patch.rb
spree_core-3.7.0.rc3 lib/friendly_id/slug_rails5_patch.rb