update variable scope