diff --git a/lib/saxerator/builder/hash_builder.rb b/lib/saxerator/builder/hash_builder.rb
index <HASH>..<HASH> 100644
--- a/lib/saxerator/builder/hash_builder.rb
+++ b/lib/saxerator/builder/hash_builder.rb
@@ -43,6 +43,7 @@ module Saxerator
       end
       
       def add_to_hash_element( hash, name, element)
+        name = @config.hash_key_generator.call(name)
         if hash[name]
           if !hash[name].is_a?(Array)
             hash[name] = ArrayElement[hash[name]]
Symbolize keys if that option is chosen along with put_attributes_in_hash