Merge pull request #7852 from pefish/patch-1

fix: returned error not be accept correctly
This commit is contained in:
Łukasz Magiera 2022-01-03 19:57:43 +01:00 committed by GitHub
commit 9b11c4b319
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -181,9 +181,10 @@ func (s *WindowPoStScheduler) runSubmitPoST(
post.ChainCommitRand = commRand
// Submit PoST
sm, submitErr := s.submitPoStMessage(ctx, post)
if submitErr != nil {
log.Errorf("submit window post failed: %+v", submitErr)
sm, err := s.submitPoStMessage(ctx, post)
if err != nil {
log.Errorf("submit window post failed: %+v", err)
submitErr = err
} else {
s.recordProofsEvent(post.Partitions, sm.Cid())
}