get_category_parents produces fatal error
|Reported by:||tar.gz||Owned by:|
On a test install of WP 3.1 , I notice that this function is broken: it produces an error when called inside the single post template.
Using this code :
<?php echo get_category_parents($cat, TRUE, ' » '); ?>
produces the following error message: Catchable fatal error: Object of class WP_Error could not be converted to string in (.../themes/twentyten/loop-single.php). This effects every post.
I did not spot this error in 3.1-beta1-16723, so I believe it has been introduced after that build.
To rule out any error in my custom theme, I tested it with the Twenty Ten 1.3-alpha theme, adding the function above inside loop-single.php (at line 32, just above the content). It produces the same error message.
Possibly related issue: #7030