some minor code cleaning