Pref input validation, controlable pref loading, more strict pref type checking