AxeWP / wp-graphql-rank-math

Add GraphQL support for RankMath SEO
GNU General Public License v3.0
50 stars 7 forks source link

Sitemap: `post__not_in` requires a value to be an array #62

Closed marcinkrzeminski closed 10 months ago

marcinkrzeminski commented 10 months ago

What

I was getting an error saying: array_map(): Argument #2 ($array) must be of type array, string given when I have defined IDs to be excluded from the sitemap.

How

Getting an array by exploding the string and using array_map with an absint (like it's done in other places in the plugin).

Checklist:

justlevine commented 10 months ago

Thanks so much for this PR @marcinkrzeminski !

I've updated the PR to apply this fix to Sitemap terms as well.