Switch to using preferences