error in deleting devices