Skip to content

Commit

Permalink
Fixed with solution located at google/gson#712
Browse files Browse the repository at this point in the history
  • Loading branch information
JayTSmith committed Oct 17, 2017
1 parent fab7faf commit 1128db7
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ public RuntimeTypeAdapterFactory<T> registerSubtype(Class<? extends T> type) {
}

public <R> TypeAdapter<R> create(Gson gson, TypeToken<R> type) {
if (type.getRawType() != baseType) {
if (null == type || !baseType.isAssignableFrom(type.getRawType())) {
return null;
}

Expand Down

0 comments on commit 1128db7

Please sign in to comment.