public function getFavorites(Tree $tree): array
    {
        return DB::table('favorite')
            ->where('gedcom_id', '=', $tree->id())
            ->whereNull('user_id')
            ->get()
            ->map(static function (stdClass $row) use ($tree): stdClass {
                if ($row->xref !== null) {
                    $row->record = GedcomRecord::getInstance($row->xref, $tree);
                } else {
                    $row->record = null;
                }

                return $row;
            })
            ->all();
    }