clear up some code