Skip to content

Commit eb5f0f8

Browse files
committed
null check
1 parent 54f0851 commit eb5f0f8

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

  • packages/components/src/internal/components/editable

packages/components/src/internal/components/editable/actions.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -449,7 +449,7 @@ async function convertRowToEditorModelData(
449449
let message: CellMessage;
450450
let valueDescriptors = List<ValueDescriptor>();
451451

452-
if (data && col && col.isPublicLookup()) {
452+
if (data && col?.isPublicLookup()) {
453453
// value had better be the rowId here, but it may be several in a comma-separated list.
454454
// If it's the display value, which happens to be a number, much confusion will arise.
455455
const values = data.toString().split(',');
@@ -461,7 +461,7 @@ async function convertRowToEditorModelData(
461461
}
462462
} else {
463463
let display = data;
464-
if (col.isTimeOrDateTimeColumn && typeof data === 'string') {
464+
if (col?.isTimeOrDateTimeColumn && typeof data === 'string') {
465465
display = getDateTimeDisplayValueFromStr(data, col);
466466
}
467467
valueDescriptors = valueDescriptors.push({ display, raw: data });

0 commit comments

Comments
 (0)