-fixed bug with delete