Cleaning a few routines