Error with 1.11.13 and other get_posts
-
Hi,
I just updated to the newest version (1.11.13) and encountered a 500 Error on the Site.
The error states a undefined methodis_user_logged_in
in the accesspress-anonymous-post plugin. But since this error only occurs when updating Broken Link Checker – so I digged into it.
is_user_logged_in
is a pluggable function which is not available very early and get’s called in apre_get_posts
hook by the accesspress-anonymous-post plugin. Until now this wasn’t a problem because theresynch
method ofblcPostTypeOverlord
used a custom SQL query to get posts, but now it usesget_posts
which usesWP_Query
and calls all those hooks. I can’t quite figure out when and how theresnych
get’s started but it seems to be too early foris_user_logged_in
to be available (= beforeinit
?). Maybe asuppress_hooks
would be enough?
I don’t think it’s the fault of accesspress-anonymous-post plugin, because it call’s the method in thepre_get_posts
hook and in this hook theis_user_logged_in
should be defined normally.
- The topic ‘Error with 1.11.13 and other get_posts’ is closed to new replies.