Use transaction for settings commit