tractorcow / silverstripe-dynamiccache

Simple on the fly caching of dynamic content for Silverstripe
39 stars 27 forks source link

Ignore UserDefinedForms from cache #17

Closed jyrkij closed 10 years ago

jyrkij commented 10 years ago

Closes #16

tractorcow commented 10 years ago

I suggest we make the list of "ignored classes" a config value, that way users can set it on a project by project basis. How do you feel about this?

I.e.

DynamicCache:
  ignored_pages:
    - 'ErrorPage'
    - 'UserDefinedForm'
tractorcow commented 10 years ago

I'll merge this for now and implement my idea separately. :) Thanks for the help @jyrkij

tractorcow commented 10 years ago

@jyrkij I've tested this update out and it seems to work well on my end; Are you happy with the way I've implemented this solution?

https://github.com/tractorcow/silverstripe-dynamiccache/commit/ca58f8fc2d0211b35cbda23ba0354eeb6f0d4d83

If you do a recent update, just make sure to do a flush to clear any already-cached form / error pages.

jyrkij commented 10 years ago

Looks good to my eyes. I'll update our clone.