Implemented delete method.