Skip to content

Commit 0987fc2

Browse files
committed
Quick fix regarding attesters calculation
1 parent e17a224 commit 0987fc2

File tree

1 file changed

+4
-1
lines changed
  • lib/lambda_ethereum_consensus/validator

1 file changed

+4
-1
lines changed

lib/lambda_ethereum_consensus/validator/duties.ex

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,10 @@ defmodule LambdaEthereumConsensus.Validator.Duties do
5555
|> Enum.flat_map(fn slot ->
5656
0..(committee_count_per_slot - 1)
5757
|> Enum.flat_map(&compute_duties_per_committee(state, epoch, slot, validators, &1))
58-
|> Enum.map(&{slot, &1})
58+
|> case do
59+
[] -> []
60+
duties -> [{slot, duties}]
61+
end
5962
end)
6063
|> Map.new()
6164
end

0 commit comments

Comments
 (0)