Skip to content

Commit

Permalink
Change to use nullish coalescing operator
Browse files Browse the repository at this point in the history
  • Loading branch information
patrikhellgren committed Mar 11, 2024
1 parent e4e90cb commit 39ca5d0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion search-parts/src/components/DetailsListComponent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -358,7 +358,7 @@ export class DetailsListComponent extends React.Component<IDetailsListComponentP
value = ObjectHelper.byPath(item, column.value);
}

const tempColumnValueAsHtml = new DOMParser().parseFromString(`<span>${(value !== null && value !== undefined) ? value as string : ""}</span>`, "text/html");
const tempColumnValueAsHtml = new DOMParser().parseFromString(`<span>${value ?? ""}</span>`, "text/html");

this.props.templateService.replaceDisambiguatedMgtElementNames(tempColumnValueAsHtml);

Expand Down

0 comments on commit 39ca5d0

Please sign in to comment.