bit of code cleaning