Skip to content

Commit

Permalink
boot: fix redundant error check in markSuccessful()
Browse files Browse the repository at this point in the history
This commit removes an error check that is unnecessary. No new
error is created here and err is already checked 4 lines above.
  • Loading branch information
mvo5 authored and alfonsosanchezbeato committed Jul 20, 2023
1 parent aa99a58 commit 737d582
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions boot/bootstate20.go
Original file line number Diff line number Diff line change
Expand Up @@ -880,9 +880,6 @@ func (brs20 *bootState20Model) markSuccessful(update bootStateUpdate) (bootState
// sign key ID was not being populated in earlier versions of snapd, try
// to remedy that
if u20.modeenv.ModelSignKeyID == "" {
if err != nil {
return nil, err
}
u20.writeModeenv.ModelSignKeyID = brs20.dev.Model().SignKeyID()
}
return u20, nil
Expand Down

0 comments on commit 737d582

Please sign in to comment.