Fixed error and removed ugly test code