Bug fixes for settings