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.14.1 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.2.3.1 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.1.13.1 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.0.7.1 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.2.3 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.2.2 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.2.1 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.0.7 lib/friendly_id/slug_rails5_patch.rb
spree_core-3.7.14 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.2.0 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.2.0.rc5 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.2.0.rc4 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.2.0.rc3 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.1.13 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.0.6 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.2.0.rc2 lib/friendly_id/slug_rails5_patch.rb
spree_core-3.7.13 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.0.5 lib/friendly_id/slug_rails5_patch.rb
spree_core-4.1.12 lib/friendly_id/slug_rails5_patch.rb
spree_core-3.7.12 lib/friendly_id/slug_rails5_patch.rb