title: Delete model resource link in Action Mailer View
body: <p>I'm having a bit of trouble generating a link in Action Mailer that allows the resource to be deleted when clicked. Here's my code for the delete method (which works fine inside of the app):</p>
  
  <pre><code>def destroy
      @registrant = Registrant.find(params[:id])
      @registrant.destroy
      flash[:danger] = "Your registration has successfully been cancelled."
      redirect_to root_url
      RegistrantMailer.cancellation_email(@registrant, @registrant.event).deliver_now
      rescue
        flash[:warning] = "No registration record found."
        redirect_to root_url
    end
  </code></pre>
  
  <p>Here are the routes for the application:</p>
  
  <pre><code>Prefix Verb   URI Pattern                     Controller#Action
           registrants POST   /registrants(.:format)          registrants#create
            registrant GET    /registrants/:id(.:format)      registrants#show
                       DELETE /registrants/:id(.:format)      registrants#destroy
  static_pages_contact GET    /static_pages/contact(.:format) static_pages#contact
    static_pages_about GET    /static_pages/about(.:format)   static_pages#about
                events GET    /events(.:format)               events#index
                       POST   /events(.:format)               events#create
             new_event GET    /events/new(.:format)           events#new
            edit_event GET    /events/:id/edit(.:format)      events#edit
                 event GET    /events/:id(.:format)           events#show
                       PATCH  /events/:id(.:format)           events#update
                       PUT    /events/:id(.:format)           events#update
                       DELETE /events/:id(.:format)           events#destroy
                  root GET    /                               static_pages#home
  </code></pre>
  
  <p>And here is the link from the mailer in which I want to generate the delete link:</p>
  
  <pre><code>&lt;p&gt;Can't make the event? Click here to cancel your registration: &lt;%= link_to 'Destroy', @registrant, method: :delete %&gt; &lt;/p&gt;
  </code></pre>