Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃悰 Avoid Hive.init cause conflicts with box paths #504

Merged
merged 1 commit into from
Oct 25, 2023

Conversation

AlexV525
Copy link
Member

(downstream AstroxNetwork/flutter_webf@eb95a17)

Hive.init will update the homePath of the HiveImpl, which will lead to newly opened boxes using the new base path.

https://github.com/isar/hive/blob/470473ffc1ba39f6c90f31ababe0ee63b76b69fe/hive/lib/src/hive_impl.dart#L57

This behavior is undesirable and will cause severe storage issues for users.

@AlexV525
Copy link
Member Author

The PR fixes it by always opening the box with a fixed path.

@AlexV525 AlexV525 added this pull request to the merge queue Oct 25, 2023
Merged via the queue into main with commit 284e21b Oct 25, 2023
24 checks passed
@AlexV525 AlexV525 deleted the fix/hive-init-conflicts branch October 25, 2023 16:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants