Fixed weird hash issue. Fixes #10 and fixes #7