avoided use of global configuration by using an 'option' struct