Skip to content
This repository has been archived by the owner on Jul 24, 2024. It is now read-only.

Commit

Permalink
restore: populate restore cancel error (#207)
Browse files Browse the repository at this point in the history
Signed-off-by: Neil Shen <overvenus@gmail.com>

Co-authored-by: kennytm <kennytm@gmail.com>
  • Loading branch information
overvenus and kennytm authored Mar 25, 2020
1 parent 2f083c8 commit 1f27b57
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/restore/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -476,7 +476,7 @@ func (rc *Client) RestoreFiles(
defer wg.Done()
select {
case <-rc.ctx.Done():
errCh <- nil
errCh <- rc.ctx.Err()
case errCh <- rc.fileImporter.Import(fileReplica, rewriteRules):
updateCh.Inc()
}
Expand Down Expand Up @@ -527,7 +527,7 @@ func (rc *Client) RestoreRaw(startKey []byte, endKey []byte, files []*backup.Fil
defer wg.Done()
select {
case <-rc.ctx.Done():
errCh <- nil
errCh <- rc.ctx.Err()
case errCh <- rc.fileImporter.Import(fileReplica, emptyRules):
updateCh.Inc()
}
Expand Down

0 comments on commit 1f27b57

Please sign in to comment.