Refactor settings.