[prefs] Account for errors in onChange handlers