working on some code cleaning