pantheon-systems / solr-power

A WordPress plugin to connect to Pantheon's Apache Solr search infrastructure, or your own!
https://wordpress.org/plugins/solr-power/
GNU General Public License v2.0
126 stars 60 forks source link

Remove incorrect use of array_map( 'get_post' ) in posts_pre_query #521

Closed bamadesigner closed 2 years ago

bamadesigner commented 2 years ago

Found posts don't need to be mapped for posts_pre_query filter. This mapping is taken care of by the core query.

Fixes #520.

danielbachhuber commented 2 years ago

Thanks @bamadesigner!

I'll review this at depth when I have a moment in the next week or two. It seems like a substantial change, so I want to make sure I understand it fully. If you can, it would be great to have a couple of unit tests documenting the nature of the change.

danielbachhuber commented 2 years ago

As it turns out, the test suite didn't run on this PR and there were a whole host of explosions when it did 🙃

I've fixed things up with 2f312cf466e08ef3ba35f24fcd1ea16a05fd014d (#522 )

Thanks again for the PR!

bamadesigner commented 2 years ago

Thanks @danielbachhuber!