Changed delete method to put