This is the technical support forum for WPML - the multilingual WordPress plugin.

Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.

This topic contains 1 reply, has 2 voices.

Last updated by Noman 11 months, 1 week ago.

Assigned support staff: Noman.

Author Posts
August 1, 2019 at 12:34 pm #4321703


When I update some products, not all, even products not yet translated, I get this error

Fatal error: Uncaught TypeError: Argument 1 passed to WPML_Media_Post_Images_Translation::translate_images_in_post_content() must be an instance of WP_Post, null given, called in /home/vetrine5/public_html/wp-content/plugins/wpml-media-translation/classes/media-translation/class-wpml-media-post-images-translation.php on line 107 and defined in /home/vetrine5/public_html/wp-content/plugins/wpml-media-translation/classes/media-translation/class-wpml-media-post-images-translation.php:130 Stack trace: #0 /home/vetrine5/public_html/wp-content/plugins/wpml-media-translation/classes/media-translation/class-wpml-media-post-images-translation.php(107): WPML_Media_Post_Images_Translation->translate_images_in_post_content(NULL, Object(WPML_Post_Element)) #1 /home/vetrine5/public_html/wp-includes/class-wp-hook.php(288): WPML_Media_Post_Images_Translation->translate_images(4524) #2 /home/vetrine5/public_html/wp-includes/class-wp-hook.php(310): WP_Hook->apply_filters(NULL, Array) #3 /home/vetrine5/public_html/wp-includes/plugin.php(465 in /home/vetrine5/public_html/wp-content/plugins/wpml-media-translation/classes/media-translation/class-wpml-media-post-images-translation.php on line 130

I tried disabling the WPML media plugins and updating the products, and there are no errors. When I re-enable the plugin, the errors return.

Tnx in advance

August 1, 2019 at 3:22 pm #4323431


Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)


Thank you for contacting WPML Support. Could you please below steps and let me know how it goes?

=== Please backup your database and website ===

Please go to WPML >> Support >> Troubleshooting.

Look for 'Clean up' and click the following:
- Clear the cache in WPML
- Remove ghost entries from the translation tables
- Fix element_type collation
- Set language information
- Fix post type assignment for translations

Thank you

The topic ‘[Closed] Fatal error when updating products’ is closed to new replies.