add prefs implementation