source/php/Admin/Options.php
public function acfLocationRulesMatch($match, $rule, $options)
    {
        $post_types = get_field('easy_reading_posttypes', 'option');

        if ($post_types) {
            if ($rule['operator'] == "==") {
                $match = (isset($options['post_type']) && in_array($options['post_type'], $post_types) && $options['post_id'] > 0);
            } elseif ($rule['operator'] == "!=") {
                $match = (isset($options['post_type']) && !in_array($options['post_type'], $post_types) && $options['post_id'] > 0);
            }
        }

        return $match;
    }
public function acfLocationRulesMatch($match, $rule, $options)
    {
        $post_types = get_field('easy_reading_posttypes', 'option');

        if ($post_types) {
            if ($rule['operator'] == "==") {
                $match = (isset($options['post_type']) && in_array($options['post_type'], $post_types) && $options['post_id'] > 0);
            } elseif ($rule['operator'] == "!=") {
                $match = (isset($options['post_type']) && !in_array($options['post_type'], $post_types) && $options['post_id'] > 0);
            }
        }

        return $match;
    }
public function acfLocationRulesMatch ( $ match , $ rule , $ options ) { $ post_types = get_field ( 'easy_reading_posttypes' , 'option' ) ; if ( $ post_types ) { if ( $ rule [ 'operator' ] == "==" ) { $ match = ( isset ( $ options [ 'post_type' ] ) && in_array ( $ options [ 'post_type' ] , $ post_types ) && $ options [ 'post_id' ] > 0 ) ; } elseif ( $ rule [ 'operator' ] == "!=" ) { $ match = ( isset ( $ options [ 'post_type' ] ) && ! in_array ( $ options [ 'post_type' ] , $ post_types ) && $ options [ 'post_id' ] > 0 ) ; } } return $ match ; }
Matching custom location rule
@param  boolean $match   If rule match or not
@param  array   $rule    Current rule that to match against
@param  array   $options Data about the current edit screen
@return boolean
Matching custom location rule