Refactor and remove unnecessary hash dependancy.