Skip to content

[BUG] Argument #1 is not an array in /base/controls-stack.php on line 1184 #10578

@zeinnicholas

Description

@zeinnicholas

Prerequisites

  • I have searched for similar issues in both open and closed tickets and cannot find a duplicate.
  • The issue still exists against the latest stable version of Elementor.

Description

Users have been reporting errors with WooCommerce based websites after updating to 2.9.2:

Warning: array_merge(): Argument #1 is not an array in .../wp-content/plugins/elementor/includes/base/controls-stack.php on line 1184

It has something to do with Dynamic Tags and the use of the Custom Add To Cart button inside static pages.

Update:

It seems that this issue is not related only to WooCommerce and the Custom Add To Cart Button, so it's imperative to test the Dynamic Tags being used regardless if WC is installed or not.

This page: https://docs.elementor.com/article/620-known-bugs-of-elementor does not reflect the entire issue.

As originally divulged when the button was added to the list of widgets, it's meant to be used anywhere on the entire site, not only on WC pages, so the link above is wrong and it shouldn't suggest that this is a user error (e.g: "[...] or you have a Custom Add to Cart widget on a page that is not a WC template."). As in the documentation, the description states clearly that the button is allowed to be used on the entire site:

image
See: https://docs.elementor.com/article/536-custom-add-to-cart

For more information about the issues:

https://www.facebook.com/groups/Elementors/search/?query=argument%20%231&epa=SEARCH_BOX

Steps to reproduce

WooCommerce environment:

  1. Add the Custom Add To Cart button to the homepage.

It may only happen upon updating from a previous Elementor version to the new one.

Isolating the problem

  • This bug happens with only Elementor plugin active (and Elementor Pro).
  • This bug happens with a default WordPress theme active.
  • I can reproduce this bug consistently using the steps above.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugIndicates a bug with one or multiple components.status/mergedIndicates when a Pull Request has been merged to a Release.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions