Search code examples
smartyprestashopproduct

Cannot use object of type Product as array prestashop 1.7


i have problem, when i change the declination on my product page on prestashop 1.7.1.1 when i looked for the error it look this error image

any one can help me please, im using prestashop 1.7.1.1


Solution

  • I had the same error: "Cannot use object of type Product as array".

    In Prestashop 1.7: "Objects are no longer passed to Smarty. We only use arrays now." (http://build.prestashop.com/news/module-development-changes-in-17/#general-information)

    In my case, it was a module 'productcomments'. He overwrites the "product" index and changes "array" to "object".