aboutsummaryrefslogtreecommitdiffstats
path: root/lib/arel/extensions/hash.rb
blob: 7472b5aa731ad186d4904e81f2918b3b956a6831 (plain) (blame)
1
2
3
4
5
6
7
class Hash
  def bind(relation)
    inject({}) do |bound, (key, value)|
      bound.merge(key.bind(relation) => value.bind(relation))
    end
  end
end