Protect against NPE when content type is missing
This commit is contained in:
parent
4c664a712c
commit
5d45566455
@ -313,7 +313,7 @@ public class ImportingUtilities {
|
|||||||
}
|
}
|
||||||
JSONUtilities.safePut(fileRecord, "declaredEncoding", encoding);
|
JSONUtilities.safePut(fileRecord, "declaredEncoding", encoding);
|
||||||
String contentType = null;
|
String contentType = null;
|
||||||
if (entity.getContentType().getValue() != null) {
|
if (entity.getContentType() != null) {
|
||||||
contentType = entity.getContentType().getValue();
|
contentType = entity.getContentType().getValue();
|
||||||
}
|
}
|
||||||
JSONUtilities.safePut(fileRecord, "declaredMimeType", contentType);
|
JSONUtilities.safePut(fileRecord, "declaredMimeType", contentType);
|
||||||
|
Loading…
Reference in New Issue
Block a user