replacing hash calculation by simply using strings for comparision