moves log level setting to top of file