some more code cleaning