PluginProbe
Passster – Password Protect Pages and Content / 4.3.17
Passster – Password Protect Pages and Content v4.3.17
4.3.17 4.3.16 4.3.15 4.3.14 4.3.12 4.3.13 4.3.11 4.3.10 4.3.9 4.3.8 4.3.7 4.3.6 4.3.5 trunk 3.5.4 3.5.5.2 3.5.5.8 3.5.5.9 4.0 4.1.4 4.2.10 4.2.11 4.2.12 4.2.13 4.2.14 All 49 releases
← All changes | inc/admin/inc/class-ps-admin.php +16 -15 4.3.10 → 4.3.17 View file →
@@ -166,22 +166,23 @@
166 166 'not_found' => __( 'No Protected Areas found.', 'content-protector' ),
167 167 'not_found_in_trash' => __( 'No Protected Areas found in Trash.', 'content-protector' ),
168 168 );
169 169 $args = array(
170 - 'labels' => $labels,
171 - 'description' => __( 'Manageable protected areas', 'content-protector' ),
172 - 'public' => false,
173 - 'publicly_queryable' => false,
174 - 'show_ui' => true,
175 - 'show_in_menu' => 'passster',
176 - 'query_var' => true,
177 - 'rewrite' => false,
178 - 'capability_type' => 'post',
179 - 'has_archive' => false,
180 - 'hierarchical' => false,
181 - 'menu_position' => null,
182 - 'supports' => array('title', 'editor'),
183 - 'show_in_rest' => true,
170 + 'labels' => $labels,
171 + 'description' => __( 'Manageable protected areas', 'content-protector' ),
172 + 'public' => false,
173 + 'publicly_queryable' => false,
174 + 'show_ui' => true,
175 + 'show_in_menu' => 'passster',
176 + 'query_var' => true,
177 + 'rewrite' => false,
178 + 'capability_type' => 'post',
179 + 'has_archive' => false,
180 + 'hierarchical' => false,
181 + 'menu_position' => null,
182 + 'supports' => array('title', 'editor'),
183 + 'show_in_rest' => true,
184 + 'rest_controller_class' => PS_Protected_Areas_Rest_Controller::class,
184 185 );
185 186 if ( current_user_can( 'administrator' ) && (is_plugin_active( 'elementor/elementor.php' ) || is_plugin_active( 'fusion-builder/fusion-builder.php' ) || is_plugin_active( 'livecanvas/livecanvas-plugin-index.php' ) || is_plugin_active( 'divi-builder/divi-builder.php' ) || is_plugin_active( 'oxygen/functions.php' )) ) {
186 187 $args['public'] = true;
187 188 $args['publicly_queryable'] = true;
@@ -186,9 +187,9 @@
186 187 $args['public'] = true;
187 188 $args['publicly_queryable'] = true;
188 189 }
189 190 $theme = wp_get_theme();
190 - if ( current_user_can( 'administrator' ) && 'Divi' == $theme->name || 'Divi' == $theme->parent_theme ) {
191 + if ( current_user_can( 'administrator' ) && ('Divi' == $theme->name || 'Divi' == $theme->parent_theme) ) {
191 192 $args['public'] = true;
192 193 $args['publicly_queryable'] = true;
193 194 }
194 195 register_post_type( 'protected_areas', $args );