remove unused code
code fixes