feat: init sha once explicitly from bingrid

This commit is contained in:
2025-03-06 08:47:37 +01:00
parent 47279b49cb
commit 2e87294c46

View File

@@ -621,10 +621,12 @@ type ExtendedGrid(grid: IGrid) =
// this.initNodeTree ()
Util.tryFindElement grid elementTree.Value p
member this.getSha1(?grid: BinGrid) =
if grid.IsSome && grid.Value.hash.Length > 0 then
gridSha1 <- grid.Value.hash
elif gridSha1.Length = 0 then
member this.initSha1(grid: BinGrid) =
if gridSha1.Length = 0 && grid.hash.Length > 0 then
gridSha1 <- grid.hash
member this.getSha1() =
if gridSha1.Length = 0 then
let bg : BinGrid = {
hash = [||]
vertices = (this :> IGrid).getVertices ()