Fixed bug when copying hashmap with constructor.