PP Collaborative Editing Addon
-
Hello,
Thank you for creating such a great plugin. I am just writing to inquire about act_check_ajax_referer function of PPCE_AdminHardway_Ltd class. I’ve noticed that enabling this add on utilizes ‘check_ajax_refer’ hook to perform additional checks to ensure the current user has proper permission.
// block term creation if selected parent is explicity blocked if ( $term_parent ) { $user_terms = get_terms( $taxonomy, array( 'fields' => 'ids', 'hide_empty' => false, 'required_operation' => 'associate' ) ); if ( ! in_array( $term_parent, $user_terms ) ) die(-1); }I am writing because even though I have properly setup roles and permissions, admin_ajax kept failing when I try to add a new custom taxonomy. After some debugging, I have traced the problem down to this line: ~ line 224
if ( $term_parent ) {If a custom taxonomy parent is not set, this value is always -1 which will always hit die(-1);
I was wondering if it needs to read:
if ( $term_parent > 0 ) {Thank you,
Regards.
The topic ‘PP Collaborative Editing Addon’ is closed to new replies.