fix issue that primitive values became error even if it has
persistent=false.