WAIT: Conflict with PublishPress Capabilities

Browser: All
OS: All
URL: NA

Since deploying V2, sites using PublishPress Capabilities crash for users who have custom capabilities. These users have no access to Bricks, but I suspect the new granular system in Bricks is causing the PublishPress plugin to break. Sadly, disabling one or the other is not an option, but doing so resolves the issue. I have opened a ticket with PublishPress as well, but everything was working until Bricks was updated.

I just heard back from the Publish Press team.

The cap property of a post type object is supposed to have nothing but string-valued properties. It sounds like Bricks Builder 2.0 has added another property with an array value. If so, that is going to cause a lot of compatibility issues, so you should contact their support and ask them to ensure the $post_type_obj->cap object is not corrupted with invalid property values.

The error is

PHP message: Warning: Array to string conversion in /var/www/wp-content/plugins/capabilities-pro/includes/cap-helper.php on line 65 (https://mysite/integrated-service-networks/wp-admin/) [wp-content/plugins/capabilities-pro/includes/cap-helper.php:65 array_unique(), wp-content/plugins/capabilities-pro/includes/cap-helper.php:24 CME_Cap_Helper->force_distinct_post_caps(), wp-content/plugins/capabilities-pro/includes/cap-helper.php:20 CME_Cap_Helper->refresh(), wp-content/plugins/capabilities-pro/includes/functions.php:59 CME_Cap_Helper->__construct(), wp-includes/class-wp-hook.php:324 _cme_cap_helper(), wp-includes/class-wp-hook.php:348 WP_Hook->apply_filters(), wp-includes/plugin.php:517 WP_Hook->do_action(), wp-settings.php:727 do_action(‘init’), wp-config.php:53 require_once(‘wp-settings.php’), wp-load.php:50 require_once(‘wp-config.php’), wp-admin/admin.php:35 require_once(‘wp-load.php’), wp-admin/index.php:10 require_once(‘wp-admin/admin.php’)]

1 Like

Same here. Publish Press Capabilites ist recommended by WSForm so that editors can see the tables for contact forms, etc too. For this reason I have installed it on several projects. They all crashed with fatal errors when updating to bricks 2.0. The problem is indeed the array data type. Capabilities should be strings not arrays as it is stated in the wordpress developer guides. I hope they can fix this soon somehow…