FriendsOfFlarum / pretty-mail

A Flarum extension that allows you to make custom html templates for emails!
MIT License
8 stars 1 forks source link

NotificationMailer constructor parameters changed in Flarum 1.5, override broken #29

Closed clarkwinkelmann closed 2 years ago

clarkwinkelmann commented 2 years ago

SettingsRepositoryInterface $settings was added as a third constructor parameter to NotificationMailer in Flarum 1.5.

https://github.com/flarum/framework/blob/v1.5.0/framework/core/src/Notification/NotificationMailer.php#L40

public function __construct(Mailer $mailer, TranslatorInterface $translator, SettingsRepositoryInterface $settings)

It throws an error because we are not providing the correct number of parameters in our extended class:

https://github.com/FriendsOfFlarum/pretty-mail/blob/43c8c211864b6ddb45e4da8c5df11d762c824d3c/src/Overrides/NotificationMailer.php#L50-L59

Change made in https://github.com/flarum/framework/pull/3525

betalk-ir commented 2 years ago

Hi, Any progress to fix? I just waiting for this extension to upgrade to 1.5! My forum just send alot mails to users and don't want to send email without our custom template.

clarkwinkelmann commented 2 years ago

Fixed in version 1.1.1