We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6353a8c commit cd3ff74Copy full SHA for cd3ff74
Realm/RLMObjectBase.mm
@@ -537,7 +537,7 @@ id RLMObjectThaw(RLMObjectBase *obj) {
537
}
538
539
id RLMValidatedValueForProperty(id object, NSString *key, NSString *className) {
540
- if (![[[object objectSchema] className] isEqualToString:className]) {
+ if ([object isKindOfClass:[RLMObjectBase class]] && ![[[object objectSchema] className] isEqualToString:className]) {
541
@throw RLMException(@"Invalid value: cannot initialize '%@' with value '%@'", className, object);
542
543
@try {
0 commit comments