trailblazer / cells

View components for Ruby and Rails.
https://trailblazer.to/2.1/docs/cells.html
3.06k stars 236 forks source link

Fix ArgumentError: wrong number of arguments for Cell:: Caching #507

Closed taketo1113 closed 2 weeks ago

taketo1113 commented 1 year ago

It fxied argument error Cell::Caching with conditionals helper method. And added test case with conditionals helper method for Cell::Caching.

fixed #506

apotonick commented 1 year ago

Thanks my friend! However, now Ruby 2.5 is breaking - I remember fixing that a while ago with the array trick. Your intention of this PR is to allow a cache decider without any arguments, right? def cache_enabled?; ?

taketo1113 commented 1 year ago

@apotonick

However, now Ruby 2.5 is breaking

Sorry. I fixed it.

Your intention of this PR is to allow a cache decider without any arguments, right? def cache_enabled?; ?

yes!