This project is archived and is in readonly mode.

helper :all from ActionMailer
Reported by Marc-André Lafortune | March 14th, 2011 @ 05:12 PM
The documentation for
AbstractController::Helpers#helper states that
:all is a special parameter.
Indeed, from a ActionController::Base, helper
:all will use all the helper files. It even does that by
default in Rails 3.
On the other hand, this doesn't work from
ActionMailer::Base and we get:
Missing helper file helpers/all_helper.rb
Note that ActionMailer::Base <
AbstractController::Helpers is true.
1) It would be nice if helper :all could work for
ActionMailer::Base also.
2) If it did, maybe ActionMailer::Base should call
it by default, as ActionController does
3) If it wont, and :all can not handled by all
descendants of AbstractController::Helpers, then the
doc should be updated to reflect this.
Thanks
Comments and changes to this ticket
- 
            
         ifesdjeen March 19th, 2011 @ 12:04 PM:all is handled by overwritten helper (actionpack/lib/action_controller/metal/helpers.rb), which overwrites modules_for_helpers to def modules_for_helpers(args) args += all_application_helpers if args.delete(:all) super(args) endWhat most likely happened, that method doesn't get loaded. 
 If someone from Rails team could explain a bit of background behind that situation, I could provide a patch.
 ThanksEdited by Rohit Arondekar for formatting. 
- 
            
         ifesdjeen March 19th, 2011 @ 12:05 PMFor some reason my code got all messy, please see it in that gist: https://gist.github.com/877432 
- 
         Neeraj Singh April 9th, 2011 @ 05:51 PM- State changed from new to open
- Assigned user set to José Valim
- Importance changed from  to Low
 Fix is here. Please see last two commits. 
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
<h2 style="font-size: 14px">Tickets have moved to Github</h2>
The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>
 ifesdjeen
      ifesdjeen
 Jeremy Kemper
      Jeremy Kemper
 José Valim
      José Valim
 Manfred Stienstra
      Manfred Stienstra
 Neeraj Singh
      Neeraj Singh
 Piotr Sarnacki
      Piotr Sarnacki