First open wp-config.php
file and add the following two lines:
// Disable display of errors and warnings
define( 'WP_DEBUG_DISPLAY', false );
@ini_set( 'display_errors', 0 );
The above lines must be placed before:
require_once(ABSPATH . 'wp-settings.php');
After that you will not get the error message.
This step will not solve the error, it’ll only suppress it.
Then update your WordPress and bbPress plugin. This is a known bbPress error and updating will fix it.
Note: If for some reason you still can’t access to the Admin panel, then updating bbPress and WordPress manually should fix the error.
Once you are done updating, remove (or comment out) those two lines mentioned above and see if you still get the error. On live server, you should not display error anyway, so you may keep those lines.