Mange/roadie-rails

Enabling Roadie application-wide

Opened this issue · 8 comments

Is there a way of including Roadie::Rails::Automatic in all ActionMailer::Base classes?
I've tried doing it with ActionMailer::Base.send :include, Roadie::Rails::Automatic in an initializer but no success.

Is this a limitation of this gem?
Should this be fixed?
I wish I could have the same behaviour roadie 2.x provided.

Hi. I didn't intend to implement this specifically since I dislike monkey
patching. I'm a bit surprised that it didn't work for you, though. I don't
know why it doesn't work, actually.

How many mailers do you have? Is this a big problem for you?

Well, I was surprise too and I’m not a fan of monkey-patching either but since this is supposed to be rails-specific gem we should take advantage of this bond IMHO.

I have 5 mailers and adding the same line repeatedly is annoying.
But my biggest concern is the time I’ll lose figuring out what’s going on when I create a new mailer in the future, forget about the need of including that module and then send broken emails. It’s something I’ll probably forget testing.

I believe roadie should be one of those gems that add functionality that one needs but doesn’t want to care about once the gem is installed. It should just works like version 2 did.

Well, at least that’s my perspective on this.

Am 24.Aug..2014 um 14:39 schrieb Magnus Bergmark notifications@github.com:

Hi. I didn't intend to implement this specifically since I dislike monkey
patching. I'm a bit surprised that it didn't work for you, though. I don't
know why it doesn't work, actually.

How many mailers do you have? Is this a big problem for you?

Reply to this email directly or view it on GitHub.

I'll look into it.

I have an ApplicationMailer which every other mailer has to inherit from it
Maybe that's a better solution without changing the gem itself?

I tried this approach, @PikachuEXE but it doesn’t seem to work with Roadie.
Could you make it work?
I guess there are some inferences that don’t work well with inheritance.

Best Regards,
Leonardo D. Schlossmacher.

Am 27.März.2015 um 06:16 schrieb PikachuEXE notifications@github.com:

I have an ApplicationMailer which every other mailer has to inherit from it
Maybe that's a better solution without changing the gem itself?


Reply to this email directly or view it on GitHub #17 (comment).

@leods92 I am still using roadie 2.x due to #10
So I can't try it myself yet

I'm really surprised it didn't work for you. Did you use Automatic or Mailer, @leods92?

Roadie::Rails::Automatic

Am 28.März.2015 um 16:02 schrieb Magnus Bergmark notifications@github.com:

I'm really surprised it didn't work for you. Did you use Automatic or Mailer, @leods92 https://github.com/leods92?


Reply to this email directly or view it on GitHub #17 (comment).