You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Unlike the /widget endpoint, /popular-posts doesn't detect the presence of WPML/Polylang and returns posts in the original language instead.
To Reproduce
Steps to reproduce the behavior:
Install either WPML or Polylang and translate some posts.
Load the /wp-json/wordpress-popular-posts/v1/popular-posts/ endpoint (either via AJAX or using a browser tab) and use the lang parameter to set the current locale (eg. ?lang=es).
The endpoint ignores the parameter returning posts in their original language (eg. English) instead.
Expected behavior
Like the /widget endpoint, /popular-posts should be able to detect the current locale and act accordingly.
Environment:
WordPress version: 5.6.1
Plugin version: 5.2.4
The text was updated successfully, but these errors were encountered:
Describe the bug
Unlike the
/widget
endpoint,/popular-posts
doesn't detect the presence of WPML/Polylang and returns posts in the original language instead.To Reproduce
Steps to reproduce the behavior:
lang
parameter to set the current locale (eg.?lang=es
).Expected behavior
Like the
/widget
endpoint,/popular-posts
should be able to detect the current locale and act accordingly.Environment:
The text was updated successfully, but these errors were encountered: