Commit 84072f1
authored
Fix Cell.cs
Fix: Added empty refs collection check in Cell constructor
Before computing the maximum level from the refs collection, a check is now performed to ensure that the collection is not empty. If the collection is empty, the level is set to 0 (explicitly cast to byte), preventing the "Sequence contains no elements" exception during cell construction.1 parent d68f608 commit 84072f1
1 file changed
+4
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | | - | |
13 | | - | |
| 12 | + | |
| 13 | + | |
14 | 14 | | |
15 | | - | |
| 15 | + | |
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| |||
150 | 150 | | |
151 | 151 | | |
152 | 152 | | |
153 | | - | |
| 153 | + | |
0 commit comments