Hi!

* warning: Invalid argument supplied for foreach() in /web/soundvision/soundvision/sites/all/modules/ecommerce/ec_charge/ec_charge.module on line 461.
* warning: Invalid argument supplied for foreach() in /web/soundvision/soundvision/sites/all/modules/ecommerce/ec_charge/ec_charge.module on line 461.

After I updated the e-Commerce module (from rc15 to rc17) I found these messages on the page of the Products.

How can I fix it?

Thank you for your answer!

Comments

gordon’s picture

Status: Active » Postponed (maintainer needs more info)

What version of PHP are you running?

The problem is that you have no charges created, but it is returning an empty array so it should be fine. I could wrap an if around the foreach but that is not the problem or you would get an error on line 459.

Can you do a print_r()/dpr() (if you have devel) of the $charges var on about line 460 so we can see what makes up this command.

Thanks.

Raspino’s picture

I am getting the same error at store.willoseipoku.com
I am using PHP 5.2.13.
Unfortunately, I don't understand any of the other questions you have. I am really new to Drupal.

thanks!

Raspino’s picture

The problem was solved when I disabled Charges.

At this point I don't know if I will need changes again but we'll see.
Thanks!

gordon’s picture

Did you have any charges created?

xen’s picture

I ran into something like it when upgrading from rc15 to rc18... dpm showed that the charge object didn't contain empty arrays, but FALSE instead.

Creating new charges fixed the problem, so I think it's an upgrade issue.

Raspino’s picture

Don't know how to create charges. Will have to learn that but so far all seem to be going very well.

szazo82’s picture

Fixed (after I updated to rc18).

gordon’s picture

Status: Postponed (maintainer needs more info) » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.