Commit 777b0a5fd6b48a595bfcb557cfa83c2f9970fb4d

Authored by Victor Costa
1 parent 2402b6ba

Do not cache breadcrumbs block

plugins/breadcrumbs/lib/breadcrumbs_block.rb
... ... @@ -45,6 +45,10 @@ class BreadcrumbsBlock < Block
45 45 end
46 46 end
47 47  
  48 + def cacheable?
  49 + false
  50 + end
  51 +
48 52 protected
49 53  
50 54 CMS_ACTIONS = {:edit => _('Edit'), :upload_files => _('Upload Files'), :new => _('New')}
... ...
plugins/breadcrumbs/test/unit/breadcrumbs_block_test.rb
... ... @@ -68,4 +68,8 @@ class BreadcrumbsBlockTest < ActiveSupport::TestCase
68 68 assert_equal '', instance_eval(&@block.content)
69 69 end
70 70  
  71 + should 'not be cacheable' do
  72 + assert !@block.cacheable?
  73 + end
  74 +
71 75 end
... ...