Skip to content

Commit 1c35771

Browse files
committed
- minor defensive programming improvement
1 parent b9c9126 commit 1c35771

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/com/microsoft/graph/serializer/EdmNativeTypeSerializer.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
public class EdmNativeTypeSerializer {
1212
public static <T> T deserialize(final JsonElement json, final Class<T> type, final ILogger logger) throws JsonParseException {
13-
if (json == null || !(type instanceof Class)) {
13+
if (json == null || type == null) {
1414
return null;
1515
} else if(json.isJsonPrimitive()) {
1616
return getPrimitiveValue(json, type);

0 commit comments

Comments
 (0)