[wp-trac] [WordPress Trac] #43600: “Warning: count()” error on php 7.2

WordPress Trac noreply at wordpress.org
Wed Mar 21 11:46:39 UTC 2018


#43600: “Warning: count()” error on php 7.2
--------------------------+-----------------------------
 Reporter:  SpabRice      |      Owner:
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  General       |    Version:  4.9.4
 Severity:  normal        |   Keywords:
  Focuses:  template      |
--------------------------+-----------------------------
 I'm currently working with php 7.2 and when I use get_the_content() or
 get_the_excerpt() outside of a single template, in the functions.php for
 example, I get the following Warning:

 Warning: count(): Parameter must be an array or an object that implements
 Countable in /Applications/MAMP/htdocs/wordpress/wp-kona/wp-includes/post-
 template.php on line 284

 What's wrong with it? Is it a wordpress core bug?

--
Ticket URL: <https://core.trac.wordpress.org/ticket/43600>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list