silverstripe-archive / silverstripe-newsletter

NewsletterAdmin is the CMS class for managing the newsletter system.
BSD 3-Clause "New" or "Revised" License
69 stars 59 forks source link

Extensions cannot extend Newsletter getCMSFields() #25

Closed ss23 closed 6 years ago

ss23 commented 11 years ago

From http://open.silverstripe.org/ticket/4630

I found I was unable to extend the CMSFields in the newsletter module. This simply required adding $this->extend('updateCMSFields', $ret); to the getCMSFields function which i what the attached patch has in it.

Patch Attached: http://open.silverstripe.org/attachment/ticket/4630/newsletterpatch.patch

However, I believe that the above patch will break things since updateCMSFields will run twice.

@howardgrigg

wilr commented 6 years ago

Fixed now using beforeExtending