clean up and bug fix