Plugin Directory

Changeset 2678034 for whp-hide-posts


Ignore:
Timestamp:
02/13/2022 08:46:21 PM (4 years ago)
Author:
martin7ba
Message:

Bug fix

Location:
whp-hide-posts
Files:
31 added
3 edited

Legend:

Unmodified
Added
Removed
  • whp-hide-posts/trunk/README.md

    r2674334 r2678034  
    66Tested up to: 5.9
    77Requires PHP: 7.3
    8 Stable tag: 1.0.0
     8Stable tag: 1.0.1
    99License: GPLv3 or later
    1010License URI: http://www.gnu.org/licenses/gpl-3.0.html
     
    6363
    6464== Changelog ==
     65
     66= 1.0.1 =
     67_Release Date - 13 February 2022_
     68
     69- Bug fix. Added check for enabled post type for REST API Hide.
    6570
    6671= 1.0.0 =
  • whp-hide-posts/trunk/inc/class-post-hide.php

    r2674320 r2678034  
    5656     */
    5757    public function hide_from_rest_api( $args, $request ) {
     58        if ( ! in_array( $args['post_type'], $this->enabled_post_types, true ) ) {
     59            return $args;
     60        }
     61
    5862        $hidden_ids = whp_plugin()->get_hidden_posts_ids( $args['post_type'], 'rest_api' );
    5963
  • whp-hide-posts/trunk/whp-hide-posts.php

    r2674320 r2678034  
    55 * Author:      MartinCV
    66 * Author URI:  https://www.martincv.com
    7  * Version:     1.0.0
     7 * Version:     1.0.1
    88 * Text Domain: whp-hide-posts
    99 *
     
    4949     * @var string
    5050     */
    51     private $version = '1.0.0';
     51    private $version = '1.0.1';
    5252
    5353    /**
Note: See TracChangeset for help on using the changeset viewer.