Jump to content

Checkout error [SOLVED]


nanozombi

Recommended Posts

Hi there, 

I have a site that was running correctly, then the checkout page doesn't let me go further to the payment gateway after I put all the billing and delivery details.

The error message I get is 

(1/1) FatalThrowableError

Type error: Argument 1 passed to PrestaShop\PrestaShop\Core\Payment\PaymentOption::convertLegacyOption() must be of the type array, string given

in PaymentOption.php line 337

at PaymentOption::convertLegacyOption('')

at array_map(array('PrestaShop\\PrestaShop\\Core\\Payment\\PaymentOption', 'convertLegacyOption'), array('paypal' => ''))in PaymentOptionsFinder.php line 46

at PaymentOptionsFinderCore->find()in PaymentOptionsFinder.php line 82

at PaymentOptionsFinderCore->present(false)in CheckoutPaymentStep.php line 84

at CheckoutPaymentStepCore->render(array('identifier' => 'checkout-payment-step', 'position' => 4, 'ui' => object(RenderableProxy)))in RenderableProxy.php line 52

at RenderableProxy->render(array('identifier' => 'checkout-payment-step', 'position' => 4, 'ui' => object(RenderableProxy)))in smartyfront.config.inc.php line 98

at smartyRender(array('identifier' => 'checkout-payment-step', 'position' => 4, 'ui' => object(RenderableProxy)), object(SmartyDevTemplate))in SmartyLazyRegister.php line 83

at SmartyLazyRegister->__call('smartyRender', array(array('identifier' => 'checkout-payment-step', 'position' => 4, 'ui' => object(RenderableProxy)), object(SmartyDevTemplate)))in cf311cfb65a3609fbaa9cbbd31450551adefc6d7_2.file.checkout-process.tpl.php line 28

at content_5fca224738c352_76162465(object(SmartyDevTemplate))in smarty_template_resource_base.php line 123

at Smarty_Template_Resource_Base->getRenderedTemplateCode(object(SmartyDevTemplate))in smarty_template_compiled.php line 114

at Smarty_Template_Compiled->render(object(SmartyDevTemplate))in smarty_internal_template.php line 216

at Smarty_Internal_Template->render(false, 0)in smarty_internal_templatebase.php line 232

at Smarty_Internal_TemplateBase->_execute(object(SmartyDevTemplate), null, null, null, 0)in smarty_internal_templatebase.php line 116

at Smarty_Internal_TemplateBase->fetch(null, null, null, null, false, true, false)in SmartyDevTemplate.php line 40

at SmartyDevTemplateCore->fetch()in CheckoutProcess.php line 112

at CheckoutProcessCore->render(array('file' => 'checkout/checkout-process.tpl', 'ui' => object(RenderableProxy)))in RenderableProxy.php line 52

at RenderableProxy->render(array('file' => 'checkout/checkout-process.tpl', 'ui' => object(RenderableProxy)))in smartyfront.config.inc.php line 98

at smartyRender(array('file' => 'checkout/checkout-process.tpl', 'ui' => object(RenderableProxy)), object(SmartyDevTemplate))in SmartyLazyRegister.php line 83

at SmartyLazyRegister->__call('smartyRender', array(array('file' => 'checkout/checkout-process.tpl', 'ui' => object(RenderableProxy)), object(SmartyDevTemplate)))in 53cce3adb3cefcc28f8dbde8e8041322ad52fc34_2.file.checkout.tpl.php line 194

at Block_9341068715fca224726dc57_61607326->callBlock(object(SmartyDevTemplate))in smarty_internal_runtime_inheritance.php line 248

at Smarty_Internal_Runtime_Inheritance->callBlock(object(Block_9341068715fca224726dc57_61607326), object(SmartyDevTemplate))in smarty_internal_runtime_inheritance.php line 184

at Smarty_Internal_Runtime_Inheritance->process(object(SmartyDevTemplate), object(Block_9341068715fca224726dc57_61607326))in smarty_internal_runtime_inheritance.php line 156

at Smarty_Internal_Runtime_Inheritance->instanceBlock(object(SmartyDevTemplate), 'Block_9341068715fca224726dc57_61607326', 'cart_summary', 4)in 53cce3adb3cefcc28f8dbde8e8041322ad52fc34_2.file.checkout.tpl.php line 233

at Block_2977006955fca224726d219_75504719->callBlock(object(SmartyDevTemplate))in smarty_internal_runtime_inheritance.php line 248

at Smarty_Internal_Runtime_Inheritance->callBlock(object(Block_2977006955fca224726d219_75504719), object(SmartyDevTemplate))in smarty_internal_runtime_inheritance.php line 184

at Smarty_Internal_Runtime_Inheritance->process(object(SmartyDevTemplate), object(Block_2977006955fca224726d219_75504719))in smarty_internal_runtime_inheritance.php line 156

at Smarty_Internal_Runtime_Inheritance->instanceBlock(object(SmartyDevTemplate), 'Block_2977006955fca224726d219_75504719', 'content')in 53cce3adb3cefcc28f8dbde8e8041322ad52fc34_2.file.checkout.tpl.php line 76

at content_5fca224728ce91_53481050(object(SmartyDevTemplate))in smarty_template_resource_base.php line 123

at Smarty_Template_Resource_Base->getRenderedTemplateCode(object(SmartyDevTemplate))in smarty_template_compiled.php line 114

at Smarty_Template_Compiled->render(object(SmartyDevTemplate))in smarty_internal_template.php line 216

at Smarty_Internal_Template->render()in smarty_internal_template.php line 385

at Smarty_Internal_Template->_subTemplateRender('checkout/checkout.tpl', null, 'layouts/layout-full-width.tpl', 0, 3600, array(), 2, false, null, null)in smarty_internal_runtime_inheritance.php line 125

at Smarty_Internal_Runtime_Inheritance->endChild(object(SmartyDevTemplate), 'checkout/checkout.tpl')in 9f00b0ef7bf3f7ff6aaa6cf28d73478c9c2b7942_2.file.hookDisplayOverrideTemplateFooter.tpl.php line 31

at content_5fca224724c892_74940180(object(SmartyDevTemplate))in smarty_template_resource_base.php line 123

at Smarty_Template_Resource_Base->getRenderedTemplateCode(object(SmartyDevTemplate))in smarty_template_compiled.php line 114

at Smarty_Template_Compiled->render(object(SmartyDevTemplate))in smarty_internal_template.php line 216

at Smarty_Internal_Template->render(false, 0)in smarty_internal_templatebase.php line 232

at Smarty_Internal_TemplateBase->_execute(object(SmartyDevTemplate), null, 'layouts/layout-full-width.tpl', null, 0)in smarty_internal_templatebase.php line 116

at Smarty_Internal_TemplateBase->fetch('modules/ps_legalcompliance/views/templates/hook/hookDisplayOverrideTemplateFooter.tpl', null, 'layouts/layout-full-width.tpl', null, false, true, false)in SmartyDev.php line 40

at SmartyDev->fetch('modules/ps_legalcompliance/views/templates/hook/hookDisplayOverrideTemplateFooter.tpl', null, 'layouts/layout-full-width.tpl')in FrontController.php line 683

at FrontControllerCore->smartyOutputContent('modules/ps_legalcompliance/views/templates/hook/hookDisplayOverrideTemplateFooter.tpl')in FrontController.php line 667

at FrontControllerCore->display()in Controller.php line 312

at ControllerCore->run()in Dispatcher.php line 515

at DispatcherCore->dispatch()in index.php line 2

I haven't done anything but updating the modules as Prestashop has requested.

Any idea of what can that be?

PS version is 1.7.6.5, PHP 7.2.34

Thank you very much in advance!

 

Edited by nanozombi
Marking as Solved (see edit history)
Link to comment
Share on other sites

I just found it. Prestashop updated the PayPal module that was not being used, and as it was not configured then there was an error. I just disabled the module and it worked again.

I leave the problem and the solution just in case this happens to someone else.

Stay safe!

 

  • Thanks 1
Link to comment
Share on other sites

  • 5 weeks later...
On 12/4/2020 at 1:29 PM, nanozombi said:

I leave the problem and the solution just in case this happens to someone else.

Thanks!  It helped me to find out, that the PayPal-module is my problem!

Unfortunately this solution doesn't work for me, since I want to use the Paypal-module have it configured and still I'm stuck...

Link to comment
Share on other sites

  • 1 year later...
On 1/2/2021 at 9:10 PM, WebWeber said:

Thanks!  It helped me to find out, that the PayPal-module is my problem!

Unfortunately this solution doesn't work for me, since I want to use the Paypal-module have it configured and still I'm stuck...

Hi, did you find a solution? I am in the same situation but in a 1.6 to 1.7 migration. My solution is to remove array before $ legacyOption on line 337 in PaymentOption.php. But I'm not sure that's right.

Link to comment
Share on other sites

  • 8 months later...
On 1/7/2022 at 10:07 AM, EngineLab said:

Hi, did you find a solution? I am in the same situation but in a 1.6 to 1.7 migration. My solution is to remove array before $ legacyOption on line 337 in PaymentOption.php. But I'm not sure that's right.

Hello I am having the same error reported here and I have not been able to fix it by disabling the Paypal module. How have you been able to solve it?

Link to comment
Share on other sites

  • 3 weeks later...

Hello there, 

You should check the hook of the paypal's module.

It should have an old hook "displayPaymentEU" that have probably not been correctly deleted.

As the paypal's module did not have any more the function to render this hook you have an error while displaying payments.

So the solution is : 
Remove hook "displayPaymentEU" from paypal's module and all will be fine.

  • Thanks 2
Link to comment
Share on other sites

  • 6 months later...
  • 5 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...