Code in Update function is a subset of Open function above. It will be better for code maintenance if we can refactor it into a private function with a param to handle the extra code for Open function.