Moved global values out if init into var declaration