added favorites database maintenance function