Cleaned code in destructor.