fixed clear workspace bugs