More celaning and fixing prefs