Add destroy attributes function