added return value in remove method