- Status
- Resolved
- Reported for
- WPML Multilingual CMS 4.5.3
- Resolved in
- 4.5.4
Overview of the issue
If you format your URL to use a different domain per language, you may see the following fatal error after updating to WPML 4.5.3:
PHP Fatal error: Uncaught Error: Call to a member function add_hooks() on null in …/wp-content/plugins/sitepress-multilingual-cms/classes/action-filter-loader/class-wpml-action-filter-loader.php:154
Workaround
Our developers are aware of this situation and it was fixed in WPML 4.5.4.
Alternatively, in case you can’t update your WPML, and only after making sure you have a full back up of your site:
- Edit file /plugins/sitepress-multilingual-cms/classes/url-handling/wpml-wp-login-url-converter-factory.php on line 17
- Replace:
? [ $wpml_url_converter->get_wp_login_url_converter( $sitepress ), $rules ]
with
? array_filter( [ $wpml_url_converter->get_wp_login_url_converter( $sitepress ), $rules ] )