Page 1 of 1

shopfunctionsf.php on line 590 (email troubles and others)

PostPosted: Fri Jan 02, 2015 12:08 am
by admin
hello friends, this is related to all VM3 versions and possibly also to vm2.6.x versions.

if you are getting strange notices or errors from shopfunctions like:
Notice: Trying to get property of non-object in /components/com_virtuemart/helpers/shopfunctionsf.php on line 590

actual line number may differ, but usually points to:
$view->orderDetails['details']['BT']->email

thus causing lot's of email problems or other problems related to the order processing by VM or 3rd party extensions (any), you may want to fix your VM installation with this simple step:

open:
\administrator\components\com_virtuemart\models\userfields.php

and locate the line:
Code: Select all
public function getUserFieldsFilled($_selection, &$_userData = null, $_prefix = ''){

and update it to:
Code: Select all
public function getUserFieldsFilled($_selection, $_userData = null, $_prefix = ''){


actual description of the problem for developers:
- the VM core function getUserFieldsFilled used by email handling or cart processing uses by defautl a reference to the $_userData object
- this input parameter object is within the function changed from type "object" to type "array"
- which causes lot's of problems all around VM

enjoy,
best regards, stan

(we tested the code on not-yet-released VM3.0.3 on J3.x and OPC 276+)