Follow us on
  1. // it's working well
    CSF::createTaxonomyOptions( $prefix, [
    	'taxonomy' => 'category',
    	//'taxonomy' => 'post_tag',
    ] );
    // when taxonomy value is array it's not working
    // csf-css files are not introduced
    CSF::createTaxonomyOptions( $prefix, [
    	'taxonomy' => ['post_tag','category',],
    ] );CopyCopied!

    fixed bug

    // file path: /path/codestar-framework/classes/setup.class.php
          if ( ! empty( self::$args['taxonomy_options'] ) ) {
            foreach ( self::$args['taxonomy_options'] as $argument ) {
    	        /**
    	         * fixed bug: when taxonomy value is array, it's not working.
    	         *                  csf-css files are not introduced.
    	         * @date 2021.4.4
    	         * @author fuzqing
    	         */
            	if (is_array($argument['taxonomy'])) {
    		        if ( in_array($wpscreen->taxonomy,$argument['taxonomy'])) {
    			        $enqueue = true;
    		        } elseif (is_string($argument['taxonomy'])) {
    			        if ( $wpscreen->taxonomy === $argument['taxonomy'] ) {
    				        $enqueue = true;
    			        }
    		        }
    	        }
            }
          }CopyCopied!
    Posted 2 years ago #

  2. Codestar
    Admin

    Hi,

    Thanks for fixed bug code. But a few weeks ago a users report me a bug like this:

    https://github.com/Codestar/codestar-framework/pull/96/commits/dd429ee32bac0bded1e45069bd37e50565cef02d

    and I was accepted that fix. Hmm are you sure for using latest framework version 2.2.2 ?

    Regards, Codestar

    Posted 2 years ago #
  3. Oh, I'm using Codestar Framework Version is 2.2.1.
    Thanks for your reply.

    Posted 2 years ago #

  4. Codestar
    Admin

    You're welcome

    Posted 2 years ago #