Title: Help with PHP Fatal error!
Last modified: November 24, 2016

---

# Help with PHP Fatal error!

 *  [gastronimo](https://wordpress.org/support/users/gastronimo/)
 * (@gastronimo)
 * [9 years, 6 months ago](https://wordpress.org/support/topic/help-with-php-fatal-error/)
 * I have BP networked activated on a secondary site in the main network of a WP-
   multi-network (subdomain) install.
 * I just went to activate [https://wordpress.org/plugins/bp-profile-search/](https://wordpress.org/plugins/bp-profile-search/)
   on that BP site and got a blank page. debug.log shows the following:
 *  PHP Fatal error: Call to a member function has_cap() on null in /home/mysite/
   public_html/wp-content/plugins/bp-profile-search/bps-main.php on line 158
 * line 158 obviously has to do with roles n caps.
 *  if (! $role->has_cap ($cap)) $role->add_cap ($cap);
 * I am logged in to the network as SuperAdmin, and am a member of the BP site.
 * I was also activating other BP plugins at the same time, but did not receive 
   any other errors.
 * I have no wp-admin access to this site now, and I need help ASAP!

Viewing 1 replies (of 1 total)

 *  Plugin Author [Andrea Tarantini](https://wordpress.org/support/users/dontdream/)
 * (@dontdream)
 * [9 years, 6 months ago](https://wordpress.org/support/topic/help-with-php-fatal-error/#post-8480338)
 * Hi gastronimo,
 * I’m not sure why you get that fatal error, but this workaround should remove 
   it.
 * From your FTP client or control panel, delete the directory _wp-content/plugins/
   bp-profile-search_, and that will restore your site to normal.
 * Then, before reinstalling BP Profile Search, add this code to your _functions.
   php_ or _bp-custom.php_ file:
 *     ```
       add_filter ('bps_form_caps', 'form_caps');
       function form_caps ($caps)
       {
       	return array ();
       }
       ```
   
 * Please let me know if that works for you!

Viewing 1 replies (of 1 total)

The topic ‘Help with PHP Fatal error!’ is closed to new replies.

 * ![](https://ps.w.org/bp-profile-search/assets/icon.svg?rev=1568973)
 * [BP Profile Search](https://wordpress.org/plugins/bp-profile-search/)
 * [Support Threads](https://wordpress.org/support/plugin/bp-profile-search/)
 * [Active Topics](https://wordpress.org/support/plugin/bp-profile-search/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/bp-profile-search/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/bp-profile-search/reviews/)

## Tags

 * [fatal error](https://wordpress.org/support/topic-tag/fatal-error/)
 * [php](https://wordpress.org/support/topic-tag/php/)

 * 1 reply
 * 2 participants
 * Last reply from: [Andrea Tarantini](https://wordpress.org/support/users/dontdream/)
 * Last activity: [9 years, 6 months ago](https://wordpress.org/support/topic/help-with-php-fatal-error/#post-8480338)
 * Status: not resolved