From d2cfa5eb1dc609ef7c3c92ee788e325c8cdc45d7 Mon Sep 17 00:00:00 2001 From: Bernard Xie Date: Mon, 19 Jun 2023 18:40:10 -0700 Subject: [PATCH] Update d2ast.go --- d2ast/d2ast.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/d2ast/d2ast.go b/d2ast/d2ast.go index 3398bda54..a5be3fa98 100644 --- a/d2ast/d2ast.go +++ b/d2ast/d2ast.go @@ -795,7 +795,7 @@ func (mb MapNodeBox) Unbox() MapNode { } func (mb MapNodeBox) IsBoardNode() bool { - if mb.MapKey == nil || mb.MapKey.Key == nil || len(mb.MapKey.Key.Path) == 0 { + if mb.MapKey == nil || mb.MapKey.Key == nil || len(mb.MapKey.Key.Path) != 1 { return false } switch mb.MapKey.Key.Path[0].Unbox().ScalarString() {