Optimizing some bytes.

master
Uriel Fanelli 2023-08-13 00:03:49 +02:00
parent 3c185aa40f
commit 2604347e8b
1 changed files with 2 additions and 2 deletions

View File

@ -16,7 +16,6 @@ func (mip *AbstractMulticast) AddUniqueAndSort(hier int64) {
} else { } else {
mip.HierarchyArray = append(mip.HierarchyArray, hier) mip.HierarchyArray = append(mip.HierarchyArray, hier)
log.Println("Here the numbers known:", mip.HierarchyArray) log.Println("Here the numbers known:", mip.HierarchyArray)
} }
} }
@ -132,6 +131,7 @@ func (b *AbstractBridge) WaitAndClean(entity AbstractMulticast) {
// svuotare l'array e rifare le elezioni // svuotare l'array e rifare le elezioni
if !isActive(string(brIp.String())) { if !isActive(string(brIp.String())) {
entity.HierarchyArray = entity.HierarchyArray[:0] entity.HierarchyArray = entity.HierarchyArray[:0]
entity.HierarchyArray = slices.Clip(entity.HierarchyArray)
} }
} }
} }