0

According to our New Relic, in the last 30 minutes, there have been 52 similar errors.

Error: 

Non-static method PB_Label_Wordpress_Creation_Kit::wck_generate_slug() should not be called statically

Stack:

…at /var/www/sitename/wp-content/plugins/profile-builder-labels-edit/
index.php (96)

in pb_label_edit_create_box called at ? (?)

in call_user_func_array called at /var/www/sitename/wp-includes/plugin.php (503)

in do_action called at /var/www/sitename/wp-admin/admin-ajax.php (44).

A partial of index.php is:

function pb_label_edit_create_box(){

        global $wppb_strings;
        if( is_admin() && current_user_can( 'edit_theme_options' ) ){

                //var_dump( $wppb_strings );

                $pblabel_fields = array();
                $pblabel_backup = array();
                foreach( $wppb_strings as $filename => $strings ){
                        /* set up the fields array */

                        $i = 0;
                        foreach( $strings as $string ){
                                if ( !in_array( $string, $pblabel_backup ) ) {
                                        $pblabel_fields[] = array(
                                                'type' => 'textarea',
                                                'title' => $filename . '_' . $i,
                                                'description' => 'Default: ' . $string,
                                                'default' => $string,
                                        );
                                        $pblabel_backup[PB_Label_Wordpress_Creation_Kit::wck_generate_slug( $filename ) . '_' . $i] = $string;
                                        $i++;
                                }
                        }

                }

This has been happening for a while now, would anyone know what is causing and how to resolve this?

Ivan RL
  • 81
  • 13
  • Is that an error or a warning? – Stevish Apr 11 '16 at 20:24
  • According to New Relic, it's an error. Our applications is getting > 5.0% error rate and thus receiving daily e-mails notifying us. – Ivan RL Apr 11 '16 at 20:29
  • I was looking at http://stackoverflow.com/questions/4684454/error-message-strict-standards-non-static-method-should-not-be-called-staticall but not really sure how to add 'public static' in this instance. – Ivan RL Apr 11 '16 at 20:31

1 Answers1

0

The error says it all: the function wck_generate_slug is called statically, when it shouldn't.

However, there is no reason to further investigate this because it's an old code.

Profile Builder has released an add-on that is actively maintained: Labels Edit Add-on. It allows editing of Profile Builder labels, through an easy to use interface.