fix var assignment