• Hello!

    I have a WooCommerce site working with Admin Editor. Today I found an error message in server log :

    [Sun Jun 02 07:11:12.126486 2024] [proxy_fcgi:error] [pid 224226:tid 139853186459392] [client 36.225.25.130:0] AH01071: Got error 'PHP message: PHP Warning:  Undefined array key 2 in /home/runcloud/webapps/****shop/wp-admin/includes/menu.php on line 181', referer: https://shop.****.com/wp-admin/edit.php?post_type=product

    This is the codes from line 173 to line 184 in /wp-admin/includes/menu.php:

    /*
     * If there is only one submenu and it is has same destination as the parent,
     * remove the submenu.
     */
    if ( ! empty( $submenu[ $data[2] ] ) && 1 === count( $submenu[ $data[2] ] ) ) {
        $subs      = $submenu[ $data[2] ];
        $first_sub = reset( $subs );
    
        if ( $data[2] === $first_sub[2] ) {
            unset( $submenu[ $data[2] ] );
        }
    }

    This happens every time I update a product. For now I haven’t noticed any problems in the frontend nor the backend (except the product edit page is a bit slow in backend).

    I’m not sure if this issue is related to Admin Editor, but I will be appreciated if you could help me take a loo at it!

    Thanks!

    • This topic was modified 2 months ago by Hannah Kao.
    • This topic was modified 2 months ago by Hannah Kao.
Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Janis Elsts

    (@whiteshadow)

    A quick way to test if the issue is related to Admin Menu Editor is to temporarily deactivate the plugin and then try to reproduce the issue (i.e. update a product). Does another warning show up in the log? If it does, it’s probably not related to this plugin.

    Based on the code where the warning happens, I would guess that it’s triggered by an admin menu item that doesn’t have a URL or a slug. However, it’s not possible to identify the specific plugin (or theme) that created the item just from the warning message.

    Thread Starter Hannah Kao

    (@t608183)

    Hi, Janis

    You are right, they are nothing to do with Admin Editor! I really shouldn’t consider all the warnings with keyword “admin” and “menu” are all triggered by Admin Editor……

    Anyway, Thank you for the advice and quick reply!

    Hannah

Viewing 2 replies - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.