Had to change the __del__ method