added a lock on deletion. Can only delete 1 item at a time