{"id":15415005,"date":"2022-03-01T13:53:29","date_gmt":"2022-03-01T13:53:29","guid":{"rendered":"https:\/\/wordpress.org\/support\/?post_type=topic&#038;p=15415005"},"modified":"2022-03-01T13:59:35","modified_gmt":"2022-03-01T13:59:35","slug":"php-warning-on-comments-php","status":"publish","type":"topic","link":"https:\/\/wordpress.org\/support\/topic\/php-warning-on-comments-php\/","title":{"rendered":"PHP Warning: on comments.php"},"content":{"rendered":"<p>I am using WordPress 5.9.1 in a multisite install, Graphene Theme version 2.8.6, PHP version 8.0.<\/p>\n<p>The following warning error is sometimes generated in the log:<br \/>\n<code>PHP Warning: Attempt to read property &quot;display_name&quot; on bool in \/home\/*****\/***\/blog\/wp-content\/themes\/graphene\/inc\/comments.php on line 232<\/code><\/p>\n<p>I can see that it is generated if the previous line in comments.php does not get a valid WP User object and instead returns a boolean false.  <\/p>\n<p>I suggest that this function graphene_comment_author_link( $user_id ) be updated to return <code>$author_link = get_comment_author_link();<\/code> if the line <code>$author = get_userdata( $user_id );<\/code> returns a boolean false.<\/p>\n","protected":false},"template":"","class_list":["post-15415005","topic","type-topic","status-publish","hentry"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/15415005","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic"}],"about":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":2,"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/15415005\/revisions"}],"predecessor-version":[{"id":15415012,"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/15415005\/revisions\/15415012"}],"wp:attachment":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/media?parent=15415005"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}