Fixed cleanup process on deploy.