check if record is destroy before save