mirror of
https://github.com/Kingsrook/qqq.git
synced 2025-07-18 13:10:44 +00:00
Fixed NPE with null value from possible values
This commit is contained in:
@ -223,6 +223,7 @@ public class ExcelExportStreamer implements ExportStreamerInterface
|
|||||||
}
|
}
|
||||||
catch(Exception e)
|
catch(Exception e)
|
||||||
{
|
{
|
||||||
|
LOG.error("Exception generating excel file", e);
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
workbook.finish();
|
workbook.finish();
|
||||||
@ -248,7 +249,11 @@ public class ExcelExportStreamer implements ExportStreamerInterface
|
|||||||
Serializable value = qRecord.getValue(field.getName());
|
Serializable value = qRecord.getValue(field.getName());
|
||||||
if(field.getPossibleValueSourceName() != null)
|
if(field.getPossibleValueSourceName() != null)
|
||||||
{
|
{
|
||||||
value = Objects.requireNonNullElse(qRecord.getDisplayValue(field.getName()), value);
|
String displayValue = qRecord.getDisplayValue(field.getName());
|
||||||
|
if(displayValue != null)
|
||||||
|
{
|
||||||
|
value = displayValue;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(value != null)
|
if(value != null)
|
||||||
|
Reference in New Issue
Block a user