implementation of remove item feature.