Sha256: 862c8da7a0f6b0839fa25cfdf6a2abe54f71331c3a3cc64d1e430f5731ff6e14

Contents?: true

Size: 359 Bytes

Versions: 13

Compression:

Stored size: 359 Bytes

Contents

# frozen_string_literal: true

module Decidim
  # Helper overrides for the ActionView::Helpers::CacheHelper in order to take
  # locale into account for fragment caching.
  module CacheHelper
    # See: https://git.io/J3ouj
    def cache(name = {}, options = {}, &)
      name = Array(name) + [current_locale]

      super(name, options, &)
    end
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
decidim-core-0.29.1 app/helpers/decidim/cache_helper.rb
decidim-core-0.28.4 app/helpers/decidim/cache_helper.rb
decidim-core-0.29.0 app/helpers/decidim/cache_helper.rb
decidim-core-0.28.3 app/helpers/decidim/cache_helper.rb
decidim-core-0.29.0.rc4 app/helpers/decidim/cache_helper.rb
decidim-core-0.29.0.rc3 app/helpers/decidim/cache_helper.rb
decidim-core-0.29.0.rc2 app/helpers/decidim/cache_helper.rb
decidim-core-0.29.0.rc1 app/helpers/decidim/cache_helper.rb
decidim-core-0.28.2 app/helpers/decidim/cache_helper.rb
decidim-core-0.28.1 app/helpers/decidim/cache_helper.rb
decidim-core-0.28.0 app/helpers/decidim/cache_helper.rb
decidim-core-0.28.0.rc5 app/helpers/decidim/cache_helper.rb
decidim-core-0.28.0.rc4 app/helpers/decidim/cache_helper.rb