fixed database prefr issue