Jump to content

Prestashop 8.1.X - Argument #1 ($addressId) must be of type int, null given - Order Address ID not valid


webbrent

Recommended Posts

Hi Everyone,

The first time this happened I was like okay that is bizarre and shrugged it off, but now it has happened a 2nd and a 3rd time. So now it is no longer a coincidence .

Prestashop - 8.1.7
PHP - 8.1.29

I have had customers checkout their order only for their order to throw an error when attempting to open the order in the backend. The error being as per the attached.


Screenshot2025-03-19at08_54_42.thumb.png.827b7760bc021b35a0076d766746ed65.png



After reviewing of the issue it was found that the id_address_delivery field contained a customer address ID that was non existent as per the screenshots attached.


Screenshot2025-03-19at08_36_27.thumb.png.97fd1affb2121b67e409f511ca5c19ed.png



Screenshot2025-03-19at08_37_55.thumb.png.74cc5cd4b8eaeda3f9c124aa4bf2cbfb.png



A simple fix was just to add the correct customer address ID's to the Database and then the order became accessible in the backend. My concern though is how is this happening? Once is a coincidence but it is now 3 times that this has happened. Each time it has been a customer processing an order from the front-end.

Link to comment
Share on other sites

  • 2 weeks 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...