Skip to content

Commit cbd06f9

Browse files
committed
fix: capacity fix for horizon
Signed-off-by: Tomás Migone <[email protected]>
1 parent a31c9b7 commit cbd06f9

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/mappings/helpers/helpers.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1175,7 +1175,8 @@ export function calculateCapacitiesHorizon(indexer: Indexer): Indexer {
11751175
.minus(indexer.thawingTokens)
11761176
.plus(indexer.delegatedCapacity)
11771177
indexer.availableStake = indexer.tokenCapacity
1178-
.minus(indexer.allocatedTokens)
1178+
.minus(indexer.allocatedTokens) // this includes both legacy and horizon allos
1179+
.plus(indexer.legacyAllocatedTokens) // so we add the legacy tokens back
11791180
return indexer
11801181
}
11811182

0 commit comments

Comments
 (0)