pronamic / wp-pronamic-events

Pronamic Events is a basic plugin to add some Events functionality.
http://www.pronamic.eu/plugins/pronamic-events/
5 stars 3 forks source link

Fix post type check for rss feed #102

Closed jeffreyvr closed 3 months ago

jeffreyvr commented 4 months ago

Fixes the error like below that is occurring when you load the author rss feed (post type query var is empty) or when the post type query var is an array.

PHP Fatal error:  Uncaught TypeError: Illegal offset type in /site/wp-includes/post.php:2285
Stack trace:
#0 /site/wp-content/plugins/pronamic-events/classes/class-feed-module.php(33): post_type_supports(Array, 'pronamic_event')
#1 /site/wp-includes/class-wp-hook.php(324): Pronamic_Events_FeedModule->rss2_ns('')