Removing global variable