title: Undefined method `contacts_path' in Rails with Spree
body: <p>I'm trying to add a contact form to my spree-based site. Here's the error I have currently:</p>
  
  <pre><code>Showing /Users/louisstephancruz/loosecanon/app/views/spree/contacts/new.html.erb where     line #7 raised:
  
  undefined method `contacts_path' for #&lt;#&lt;Class:0x007fe8a4703de0&gt;:0x007fe8a4702670&gt;
  </code></pre>
  
  <p>Here's the relevant view file (new.html.erb):</p>
  
  <pre><code>&lt;% provide(:title, 'Contact') %&gt;
  &lt;h1&gt;Contact&lt;/h1&gt;
  
  &lt;div align="center"&gt;
    &lt;h3&gt;Send Us a Message&lt;/h3&gt;
  
    &lt;%= simple_form_for @contact, :html =&gt; {:class =&gt; 'form-horizontal' } do |f| %&gt;
      &lt;%= f.input :name, :required =&gt; true %&gt;
      &lt;%= f.input :email, :required =&gt; true %&gt;
      &lt;%= f.input :message, :as =&gt; :text, :required =&gt; true %&gt;
      &lt;div class= "hidden"&gt;
        &lt;%= f.input :nickname, :hint =&gt; 'Leave this field blank!' %&gt;
      &lt;/div&gt;
      &lt;div&gt;
        &lt;/br&gt;
        &lt;%= f.button :submit, 'Send message', :class=&gt; "btn btn-primary" %&gt;
      &lt;/div&gt;
    &lt;% end %&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>contacts_controller.rb:</p>
  
  <pre><code>module Spree
    class ContactsController &lt; Spree::HomeController
  
      def new
        @contact = Contact.new
      end
  
      def create
        @contact = Contact.new(params[:contact])
        @contact.request = request
        if @contact.deliver
          flash.now[:error] = nil
          flash.now[:notice] = 'Thank you for your message!'
        else
          flash.now[:error] = 'Cannot send message.'
          render :new
        end
      end
    end
  end
  </code></pre>
  
  <p>In my routes, I've got:</p>
  
  <pre><code>match '/contacts', to: 'spree/contacts#new', via: 'get', :as =&gt; :contacts
  resources "contacts", only: [:new, :create]
  </code></pre>
  
  <p>Gemfile:</p>
  
  <pre><code>source 'https://rubygems.org'
  ruby '2.1.2'
  
  gem 'rails', '4.0.5'
  gem 'sprockets'
  gem 'pg'
  gem 'sass-rails', '~&gt; 4.0.2'
  gem 'uglifier', '&gt;= 1.3.0'
  gem 'coffee-rails', '~&gt; 4.0.0'
  gem 'jquery-rails'
  gem 'turbolinks'
  gem 'jbuilder', '~&gt; 1.2'
  gem 'mail_form'
  gem 'simple_form'
  
  group :doc do
    # bundle exec rake doc:rails generates the API under doc/api.
    gem 'sdoc', require: false
  end
  
  group :production do
    gem 'rails_12factor'
  end
  
  gem 'ckeditor', '~&gt; 4.0.6'
  gem 'paperclip'
  gem 'aws-sdk'
  
  gem 'spree', '2.2.2'
  gem 'spree_gateway', :git =&gt; 'https://github.com/spree/spree_gateway.git', :branch =&gt; '2-2-stable'
  gem 'spree_auth_devise', :git =&gt; 'https://github.com/spree/spree_auth_devise.git', :branch =&gt; '2-2-stable'
  gem 'spree_fancy', :git =&gt; 'git://github.com/spree/spree_fancy.git', :branch =&gt; '2-2-stable'
  gem 'spree_digital', :git =&gt; 'git://github.com/halo/spree_digital.git', :branch =&gt; '2-2-stable'
  gem 'spree_blogging_spree', github: 'stefansenk/spree-blogging-spree'
  gem 'spree_editor', github: 'spree/spree_editor', :branch =&gt; '2-2-stable'
  gem 'spree_related_products', github: 'spree/spree_related_products', branch: '2-2-stable'
  </code></pre>
  
  <p>I've tried moving the controller/view files out of the spree folder, and I've also tried a dozen things in the routes file. What am I missing here?</p>
  
  <p><strong>Edit</strong></p>
  
  <p>Rake routes (the relevant stuff):</p>
  
  <pre><code>     Prefix Verb URI Pattern             Controller#Action
        spree      /                       Spree::Core::Engine
     ckeditor      /ckeditor               Ckeditor::Engine
        about GET  /about(.:format)        spree/static_pages#about
     contacts GET  /contacts(.:format)     spree/contacts#new
              POST /contacts(.:format)     contacts#create
  new_contact GET  /contacts/new(.:format) contacts#new
  </code></pre>