Only activate logging when the configuration is set properly