Skip to content

Commit 9ec83cb

Browse files
committed
Fix exception because a default non-null id is used, but not usable
1 parent 546e54e commit 9ec83cb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/src/anchor.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ class AnchorKey extends GlobalKey {
1313
}
1414

1515
static AnchorKey? forId(Key? parentKey, String? id) {
16-
if (parentKey == null || id == null || id.isEmpty) {
16+
if (parentKey == null || id == null || id.isEmpty || id == "[[No ID]]") {
1717
return null;
1818
}
1919
return AnchorKey._(parentKey, id);

0 commit comments

Comments
 (0)