title: Rails accepts_nested_attributes_for Error, please help me spot it
body: <p>I have been trying to follow the <a href="http://api.rubyonrails.org/classes/ActiveRecord/NestedAttributes/ClassMethods.html" rel="noreferrer">Active Record Nested Attributes Guide</a>, without much success.</p>
  
  <p>I have the following models:</p>
  
  <pre><code>class Contact &lt; ActiveRecord::Base
    has_many :telephones
    accepts_nested_attributes_for :telephones
  end
  
  class Telephone &lt; ActiveRecord::Base
    belongs_to :contact
  end
  </code></pre>
  
  <p>When trying to create a contact:</p>
  
  <pre><code>contact = {
    :name =&gt; "John",
    :telephones =&gt; [
      {:telephone =&gt; '787445741'},
      {:telephone =&gt; '478589658'}
    ]
  }
  Contact.create(contact)
  </code></pre>
  
  <p>I get the following error:
  <code>ActiveRecord::AssociationTypeMismatch: Telephone(#80827590) expected, got Hash(#72886250)</code></p>
  
  <p>Could you please help me spot the error?
  Is there any code that I should include in the <code>contact_controller.rb</code>?</p>