Attempt to solve bug by using a local variable.