title: Add key value pair to Array of Hashes when unique Id's match
body: <p>I have two arrays of hashes</p>
  
  <pre><code>sent_array = [{:sellersku=&gt;"0421077128", :asin=&gt;"B00ND80WKY"},
  {:sellersku=&gt;"0320248102", :asin=&gt;"B00WTEF9FG"}, 
  {:sellersku=&gt;"0324823180", :asin=&gt;"B00HXZLB4E"}]
  
  active_array = [{:price=&gt;39.99, :asin1=&gt;"B00ND80WKY"}, 
  {:price=&gt;7.99, :asin1=&gt;"B00YSN9QOG"}, 
  {:price=&gt;10, :asin1=&gt;"B00HXZLB4E"}]
  </code></pre>
  
  <p>I want to loop through sent_array, and find where the value in :asin is equal to the value in :asin1 in active_array, then copy the key &amp; value of :price to sent_array. Resulting in this:</p>
  
  <pre><code>final_array = [{:sellersku=&gt;"0421077128", :asin=&gt;"B00ND80WKY", :price=&gt;39.99},
  {:sellersku=&gt;"0320248102", :asin=&gt;"B00WTEF9FG"}, 
  {:sellersku=&gt;"0324823180", :asin=&gt;"B00HXZLB4E", :price=&gt;10}]
  </code></pre>
  
  <p>I tried this, but I get a TypeError - no implicit conversion of Symbol into Integer (TypeError)</p>
  
  <pre><code>sent_array.each do |x|
   x.detect { |key, value| 
    if value == active_array[:asin1]
      x[:price] &lt;&lt; active_array[:price]
    end
   }
  end
  </code></pre>