added clean function to clean