wilr / silverstripe-algolia

Handles indexing Silverstripe Pages into Algolia and providing results
BSD 3-Clause "New" or "Revised" License
13 stars 16 forks source link

objectSilverstripeUUID in one place and objectSilverstripeID in another #23

Closed brynnb closed 4 years ago

brynnb commented 4 years ago

https://github.com/wilr/silverstripe-algolia/blob/master/src/Service/AlgoliaQuerier.php#L34

https://github.com/wilr/silverstripe-algolia/blob/master/src/Service/AlgoliaIndexer.php#L114

The indexer is setting the attribute to objectSilverstripeID but the Querier is looking for objectSilverstripeUUID. This leads to it not returning any results. Not sure which is the intended name or what other ramifications might happen from changes, otherwise I'd submit a PR.

Thanks again @wilr

brynnb commented 4 years ago

And to clarify, setting it to objectSilverstripeID in the Querier makes things work as expected.

wilr commented 4 years ago

Ah ok sorry - yes I think objectSilverstripeUUID is clearer that it has nothing to do with an ID