Fixes a bug in the clean up process

Old files were partially removed