src/WPametu/UI/Field/Taxonomy.php
protected function get_options(){
        $terms = get_terms($this->name);
        if( !$terms || is_wp_error($terms) ){
            return [];
        }else{
            $result = [];
            foreach( $terms as $term ){
                $result[$term->term_id] = $term->name;
            }
            return $result;
        }
    }
protected function get_options(){
        $terms = get_terms($this->name);
        if( !$terms || is_wp_error($terms) ){
            return [];
        }else{
            $result = [];
            foreach( $terms as $term ){
                $result[$term->term_id] = $term->name;
            }
            return $result;
        }
    }
protected function get_options ( ) { $ terms = get_terms ( $ this -> name ) ; if ( ! $ terms || is_wp_error ( $ terms ) ) { return [ ] ; } else { $ result = [ ] ; foreach ( $ terms as $ term ) { $ result [ $ term -> term_id ] = $ term -> name ; } return $ result ; } }
Get terms as option

@return array
Get terms as option