Modified cleanup script.