fix where_values_hash patch to work with rails4.

This brings the number of test failures down from 13 to just three.