fixing bad enum usage