Moved settings to global scope