Flowdock
method

find_preferred_part

Importance_0
v6.1.3.1 - Show latest stable - 0 notes - Class: MailersController
find_preferred_part(*formats) public

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File railties/lib/rails/mailers_controller.rb, line 68
    def find_preferred_part(*formats) # :doc:
      formats.each do |format|
        if part = @email.find_first_mime_type(format)
          return part
        end
      end

      if formats.any? { |f| @email.mime_type == f }
        @email
      end
    end
Register or log in to add new notes.