Tuned clean() function