update var method