Skip to content

Commit

Permalink
do not force rollback when the list of checkpoints is empty
Browse files Browse the repository at this point in the history
An empty list basically assumes that there's no checkpoint on the driver, so nothing to rollback.
  • Loading branch information
KtorZ authored and Anviking committed Jun 16, 2020
1 parent 90c9b0c commit 1fab8e5
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/core/src/Cardano/Wallet/Network.hs
Original file line number Diff line number Diff line change
Expand Up @@ -391,6 +391,8 @@ follow nl tr cps yield header =
-- initiates the protocol by asking clients to rollback to the last
-- known intersection.
case (cursorSlotId nl cursor', cps) of
(sl, []) ->
step delay0 cursor'
(sl, _:_) | sl == slotId (last cps) ->
step delay0 cursor'
(sl, _) ->
Expand Down

0 comments on commit 1fab8e5

Please sign in to comment.