Skip to content

Commit

Permalink
Update for null vs. undefined
Browse files Browse the repository at this point in the history
  • Loading branch information
javagl committed May 3, 2024
1 parent 48a1b6d commit ddfc690
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/tools/gltfExtensionsUtils/StructuralMetadataUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ export class StructuralMetadataUtils {

let enumValueType: string | undefined = undefined;
const enumType = classProperty.getEnumType();
if (enumType !== undefined) {
if (enumType !== null) {
const enumObject = schema.getEnum(enumType);
if (!enumObject) {
sb.addLine(`decoded values: (no enum '${enumType}' in schema)`);
Expand All @@ -176,9 +176,9 @@ export class StructuralMetadataUtils {
const propertyModel = BinaryPropertyModels.createPropertyModelInternal(
propertyName,
type,
componentType,
componentType ?? undefined,
isArray,
count,
count ?? undefined,
valuesBufferViewData,
arrayOffsetsBufferViewData,
arrayOffsetType,
Expand Down

0 comments on commit ddfc690

Please sign in to comment.