[Plugin: OpenID] Missing check for $wp_scripts
-
When signed in with an OpenID, the following error was being displayed at the bottom of the post page:
PHP Fatal error: Call to a member function query() on a non-object in /blog/wp-content/plugins/openid/comments.php on line 182
There was a missing
isset($wp_scripts). The code sample below includes my fix and corrects a typo in your comment 😛/** * Print jQuery call for stylizing profile link. * * @action: comment_form **/ function openid_comment_profilelink() { global $wp_scripts; if ((is_single() || is_comments_popup()) && is_user_openid() && isset($wp_scripts) && $wp_scripts->query('openid')) { echo '<script type="text/javascript">stylize_profilelink()</script>'; } }Is there perhaps a more serious problem, in that $wp_scripts isn’t set?
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
The topic ‘[Plugin: OpenID] Missing check for $wp_scripts’ is closed to new replies.