Made it so that the config dialog is shown only if needed