Fix global variable setter