src/lib/Breadcrumbs.php
protected function add_category_links()
    {
        $cat_id = \absint(\get_query_var('cat'));
        $cat = \get_category($cat_id);
        $cat_parent_id = \absint($cat->parent);

        $cat_links = [];

        if ($cat_parent_id) {
            while ($cat_parent_id) {
                $cat_parent = \get_category($cat_parent_id);
                $cat_links[] = $this->makeLink(
                    $cat_parent->name,
                    \get_category_link(\absint($cat_parent->term_id))
                );
                $cat_parent_id = \absint($cat_parent->parent);
            }

            $this->links = \array_merge(
                $this->links,
                \array_reverse($cat_links)
            );
        }

        $this->links[] = $this->currentLink(
            $cat->name,
            \get_category_link($cat_id)
        );
    }
protected function add_category_links()
    {
        $cat_id = \absint(\get_query_var('cat'));
        $cat = \get_category($cat_id);
        $cat_parent_id = \absint($cat->parent);

        $cat_links = [];

        if ($cat_parent_id) {
            while ($cat_parent_id) {
                $cat_parent = \get_category($cat_parent_id);
                $cat_links[] = $this->makeLink(
                    $cat_parent->name,
                    \get_category_link(\absint($cat_parent->term_id))
                );
                $cat_parent_id = \absint($cat_parent->parent);
            }

            $this->links = \array_merge(
                $this->links,
                \array_reverse($cat_links)
            );
        }

        $this->links[] = $this->currentLink(
            $cat->name,
            \get_category_link($cat_id)
        );
    }
protected function add_category_links ( ) { $ cat_id = \ absint ( \ get_query_var ( 'cat' ) ) ; $ cat = \ get_category ( $ cat_id ) ; $ cat_parent_id = \ absint ( $ cat -> parent ) ; $ cat_links = [ ] ; if ( $ cat_parent_id ) { while ( $ cat_parent_id ) { $ cat_parent = \ get_category ( $ cat_parent_id ) ; $ cat_links [ ] = $ this -> makeLink ( $ cat_parent -> name , \ get_category_link ( \ absint ( $ cat_parent -> term_id ) ) ) ; $ cat_parent_id = \ absint ( $ cat_parent -> parent ) ; } $ this -> links = \ array_merge ( $ this -> links , \ array_reverse ( $ cat_links ) ) ; } $ this -> links [ ] = $ this -> currentLink ( $ cat -> name , \ get_category_link ( $ cat_id ) ) ; }
Called if $page === 'category'
Called if $page === category