Fix undeclared global