You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was recently trying to build a custom delivery method for this gem and tripped over a few minor things while doing so, owing to the lack of documentation. It would be helpful if there was some documentation about this in the README and/or if there was an abstract base class for delivery methods to inherit from, e.g:
moduleMailclassAbstractDeliveryattr_reader:settingsdefinitialize(settings={})@settings=settingsenddefdeliver!(message)raiseNotImplementedError,"`deliver!` method is not implemented on #{self.class.name}"endendend
One of the things that surprised me, for example, was that I needed to expose a #settings attribute with the settings hash that was passed into the constructor.
(I was also surprised by the differing return values from Message#deliver and Message#deliver!, but that's not really an issue with the delivery method, and someone already posted a PR for that: #1313.)
I’m happy to write a PR for this; just let me know whether the abstract class is desirable in addition to docs.
The text was updated successfully, but these errors were encountered:
I was recently trying to build a custom delivery method for this gem and tripped over a few minor things while doing so, owing to the lack of documentation. It would be helpful if there was some documentation about this in the README and/or if there was an abstract base class for delivery methods to inherit from, e.g:
One of the things that surprised me, for example, was that I needed to expose a
#settings
attribute with the settings hash that was passed into the constructor.(I was also surprised by the differing return values from
Message#deliver
andMessage#deliver!
, but that's not really an issue with the delivery method, and someone already posted a PR for that: #1313.)I’m happy to write a PR for this; just let me know whether the abstract class is desirable in addition to docs.
The text was updated successfully, but these errors were encountered: