Skip to content

Commit

Permalink
Fixes a missed edge case for #7213
Browse files Browse the repository at this point in the history
  • Loading branch information
nhachicha committed Dec 2, 2020
1 parent 03c5961 commit 97820b1
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 3 deletions.
22 changes: 22 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,25 @@
## 10.1.2 (YYYY-MM-DD)

### Breaking Changes
* None.

### Enhancements
* None.

### Fixes
* Complementary fix for missed edge case in https://github.com/realm/realm-java/pull/7220 where KAPT crash if we process a RealmObject referencing a type in RealmList defined in another module. (Issue [#7213](https://github.com/realm/realm-java/issues/7213), since v10.0.0).

### Compatibility
* File format: Generates Realms with format v20. Unsynced Realms will be upgraded from Realm Java 2.0 and later. Synced Realms can only be read and upgraded if created with Realm Java v10.0.0-BETA.1.
* APIs are backwards compatible with all previous release of realm-java in the 10.x.y series.
* Realm Studio 10.0.0 or above is required to open Realms created by this version.

### Internal
* Updated to Realm Sync: 10.1.3.
* Updated to Realm Core: 10.1.3.
* Updated to Object Store commit: fc6daca61133aa9601e4cb34fbeb9ec7569e162e.


## 10.1.1 (2020-10-27)

### Breaking Changes
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2165,16 +2165,15 @@ class RealmProxyClassGenerator(private val processingEnvironment: ProcessingEnvi
writer)
}
Utils.isRealmModelList(field) -> {
val fieldType = QualifiedClassName((field.asType() as DeclaredType).typeArguments[0])
val fieldTypeMetaData: ClassMetaData = classCollection.getClassFromQualifiedName(fieldType)
val fieldType = (field.asType() as DeclaredType).typeArguments[0]
RealmJsonTypeHelper.emitFillRealmListWithJsonValue(
"objProxy",
metadata.getInternalGetter(fieldName),
metadata.getInternalSetter(fieldName),
fieldName,
(field.asType() as DeclaredType).typeArguments[0].toString(),
Utils.getProxyClassSimpleName(field),
fieldTypeMetaData.embedded,
isFieldTypeEmbedded(fieldType),
writer)
}
Utils.isRealmValueList(field) -> emitStatement("ProxyUtils.setRealmListWithJsonObject(objProxy.%1\$s(), json, \"%2\$s\")", metadata.getInternalGetter(fieldName), fieldName)
Expand Down

0 comments on commit 97820b1

Please sign in to comment.