Timber\TermGetter::get_term_query_from_assoc_array PHP Метод

get_term_query_from_assoc_array() публичный статический Метод

public static get_term_query_from_assoc_array ( array $args ) : stdClass
$args array
Результат stdClass
    public static function get_term_query_from_assoc_array($args)
    {
        $ret = new \stdClass();
        $ret->args = $args;
        if (isset($ret->args['tax'])) {
            $ret->taxonomies = $ret->args['tax'];
        } else {
            if (isset($ret->args['taxonomies'])) {
                $ret->taxonomies = $ret->args['taxonomies'];
            } else {
                if (isset($ret->args['taxs'])) {
                    $ret->taxonomies = $ret->args['taxs'];
                } else {
                    if (isset($ret->args['taxonomy'])) {
                        $ret->taxonomies = $ret->args['taxonomy'];
                    }
                }
            }
        }
        if (isset($ret->taxonomies)) {
            if (is_string($ret->taxonomies)) {
                $ret->taxonomies = array($ret->taxonomies);
            }
            $ret->taxonomies = self::correct_taxonomy_names($ret->taxonomies);
        } else {
            $ret->taxonomies = get_taxonomies();
        }
        return $ret;
    }