corrected bug on remove