fixed clear function on line 1195