Migrating to hashMap