Skip to content
This repository was archived by the owner on Mar 18, 2025. It is now read-only.

Fix #352 and #353 #2

Merged
merged 3 commits into from
May 13, 2019
Merged

Fix #352 and #353 #2

merged 3 commits into from
May 13, 2019

Conversation

Gasparila
Copy link

@Gasparila Gasparila commented May 11, 2019

Q A
Bug fix? yes
New feature? no
BC breaks? no
Related Issue Fix algolia#352 algolia#353
Need Doc update no

Fix breaking change introduced in algolia#352
According to the documentation,
using custom attributes without a custom _changed? method will always
cause changes to push to the API. This behavior was lost in algolia#338

Fix unexpected behavior during transactions algolia#353
@algolia_must_reindex is reset in every validate call. This means that a record
that is updated multiple times in a transaction will only be indexed if the
final update marks as must reindex. Update the code so that once
@algolia_must_reindex is marked as true, it remains true until
explicitly unset in algolia_perform_index_tasks

Gasparila added 2 commits May 11, 2019 11:18
Fix breaking change introduced in algolia#352
According to the [documentation](https://github.com/algolia/algoliasearch-rails/blob/master/lib/README.md#630),
using custom attributes without a custom `_changed?` method will always
cause changes to push to the API. This behavior was lost in algolia#338

Fix unexpected behavior during transactions algolia#353
`@algolia_must_reindex` is reset in every validate call. This means that a record
that is updated multiple times in a transaction will only be indexed if the
final update marks as must reindex. Update the code so that once
`@algolia_must_reindex` is marked as `true`, it remains true until
explicitly unset in `algolia_perform_index_tasks`
@Gasparila Gasparila force-pushed the kevin/fix_transaction_issues branch from 36facf2 to da30909 Compare May 11, 2019 18:19
@Gasparila Gasparila force-pushed the kevin/fix_transaction_issues branch from 5987061 to c1e28a2 Compare May 11, 2019 23:48
@Gasparila Gasparila merged commit 68d3ba8 into master May 13, 2019
@newhouse
Copy link

dope! 🏆 🥇

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1.22 breaking change
3 participants