Skip to content

Commit

Permalink
Use typeof, not instanceof
Browse files Browse the repository at this point in the history
  • Loading branch information
zrhoffman committed Jul 31, 2023
1 parent 96a768d commit 03f16c0
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ export class TopologyService extends APIService {
for (const treeNode of treeNodes) {
const cachegroup = treeNode.cachegroup;
const parents: number[] = [];
if (parent instanceof Object) {
if (typeof parent !== "undefined") {
const index = topologyNodeIndicesByCacheGroup.get(parent.cachegroup) as number;
parents.push(index);
}
Expand Down

0 comments on commit 03f16c0

Please sign in to comment.