<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -1,6 +1,7 @@
 require 'rubygems'
 gem 'httparty'
 require 'httparty'
+require 'activesupport'
 require File.dirname(__FILE__) + '/ebay_products/data'
 
 class EbayProducts</diff>
      <filename>lib/ebay_products.rb</filename>
    </modified>
    <modified>
      <diff>@@ -3,7 +3,7 @@ class EbayProducts
     attr_reader :data
     
     def initialize(data)
-      @data = data
+      @data = downcase_keys(data)
     end
     
     def method_missing(method, *args)
@@ -14,10 +14,23 @@ class EbayProducts
       end
     end
     
-    # def inspect
-    #   data = @data.inject([]) { |collection, key| collection &lt;&lt; &quot;#{key[0]}: #{key[1]['data']}&quot;; collection }.join(&quot;\n    &quot;)
-    #   &quot;#&lt;#{self.class}:0x#{object_id}\n    #{data}&gt;&quot;
-    # end
+    private
+    
+    def downcase_keys(hash)
+      new_hash = {}
+      hash.keys.each do |key|
+        value = hash.delete(key)
+        new_hash[downcase_key(key)] = value
+        new_hash[downcase_key(key)] = downcase_keys(value) if value.is_a?(Hash)
+        new_hash[downcase_key(key)] = value.each{|p| downcase_keys(p) if p.is_a?(Hash)} if value.is_a?(Array)
+      end
+      new_hash
+    end
+
+    def downcase_key(key)
+      key.underscore.titlecase.downcase.gsub(' ', '_')
+    end
+        
   end
   
   class ProductInformation &lt; Data; end</diff>
      <filename>lib/ebay_products/data.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>d376c32303fcb4c0770d20a815cd99d82f89c9ba</id>
    </parent>
  </parents>
  <author>
    <name>Josh Owens</name>
    <email>joshua.owens@gmail.com</email>
  </author>
  <url>http://github.com/handcrafted/ebay_products/commit/d742f73c85bca47d730855c9c8d27a34b788bc07</url>
  <id>d742f73c85bca47d730855c9c8d27a34b788bc07</id>
  <committed-date>2009-06-23T21:55:20-07:00</committed-date>
  <authored-date>2009-06-23T21:55:20-07:00</authored-date>
  <message>Add the start of downcase stuff.</message>
  <tree>cbd76197c053f4751f5436379d6223b8ce218211</tree>
  <committer>
    <name>Josh Owens</name>
    <email>joshua.owens@gmail.com</email>
  </committer>
</commit>
