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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Made 'disableFormatUpgrade' and 'sync' compatible #3830

Merged
merged 1 commit into from
Jul 7, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ x.x.x Release notes (yyyy-MM-dd)

### Fixed
* <How to hit and notice issue? what was the impact?> ([#????](https://github.com/realm/realm-js/issues/????), since v?.?.?)
* None.
* Fixed an issue preventing opening a Realm with `disableFormatUpgrade` and a `sync` configuration, reverting part of [#3772](https://github.com/realm/realm-js/pull/3772). ([#3830](https://github.com/realm/realm-js/pull/3830), since v10.4.2)

### Compatibility
* MongoDB Realm Cloud.
Expand Down
3 changes: 0 additions & 3 deletions src/js_realm.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -676,9 +676,6 @@ bool RealmClass<T>::get_realm_config(ContextType ctx, size_t argc, const ValueTy
static const String disable_format_upgrade_string = "disableFormatUpgrade";
ValueType disable_format_upgrade_value = Object::get_property(ctx, object, disable_format_upgrade_string);
if (!Value::is_undefined(ctx, disable_format_upgrade_value)) {
if (config.force_sync_history || config.sync_config) {
throw std::invalid_argument("Options 'disableFormatUpgrade' and 'sync' are mutual exclusive.");
}
config.disable_format_upgrade = Value::validated_to_boolean(ctx, disable_format_upgrade_value, "disableFormatUpgrade");
}
}
Expand Down