Convert hashes to 1.8

Only converted lib, ignored spec as it doesn't run on 1.8.7 due to rails 4 and stuff