some code quality cleanup