Added updating for preferences