Fixes for prefs plugin