mirror of
https://github.com/status-im/realm-js.git
synced 2025-03-01 06:30:31 +00:00
wrong merge
This commit is contained in:
parent
487b6a9552
commit
1fce7cab2f
@ -432,16 +432,6 @@ void RealmClass<T>::constructor(ContextType ctx, ObjectType this_object, size_t
|
|||||||
config.schema_mode = SchemaMode::ResetFile;
|
config.schema_mode = SchemaMode::ResetFile;
|
||||||
}
|
}
|
||||||
|
|
||||||
static const String delete_realm_if_migration_needed_string = "deleteRealmIfMigrationNeeded";
|
|
||||||
ValueType delete_realm_if_migration_needed_value = Object::get_property(ctx, object, delete_realm_if_migration_needed_string);
|
|
||||||
if (!Value::is_undefined(ctx, delete_realm_if_migration_needed_value) && Value::validated_to_boolean(ctx, delete_realm_if_migration_needed_value, "deleteRealmIfMigrationNeeded")) {
|
|
||||||
if (config.schema_mode == SchemaMode::ReadOnly) {
|
|
||||||
throw std::invalid_argument("Cannot set 'deleteRealmIfMigrationNeeded' when 'readOnly' is set.");
|
|
||||||
}
|
|
||||||
|
|
||||||
config.schema_mode = SchemaMode::ResetFile;
|
|
||||||
}
|
|
||||||
|
|
||||||
static const String schema_string = "schema";
|
static const String schema_string = "schema";
|
||||||
ValueType schema_value = Object::get_property(ctx, object, schema_string);
|
ValueType schema_value = Object::get_property(ctx, object, schema_string);
|
||||||
if (!Value::is_undefined(ctx, schema_value)) {
|
if (!Value::is_undefined(ctx, schema_value)) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user