Skip to content

Commit

Permalink
Remove unneeded check
Browse files Browse the repository at this point in the history
  • Loading branch information
RebeccaMahany committed Feb 26, 2024
1 parent 379ce8b commit 001ee97
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions ee/tuf/autoupdate.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ import (
"path"
"path/filepath"
"runtime"
"slices"
"strconv"
"sync"
"time"
Expand Down Expand Up @@ -322,11 +321,7 @@ func (ta *TufAutoupdater) Do(data io.Reader) error {
// FlagsChanged satisfies the FlagsChangeObserver interface, allowing the autoupdater
// to respond to changes to autoupdate-related settings.
func (ta *TufAutoupdater) FlagsChanged(flagKeys ...keys.FlagKey) {
if !slices.Contains(flagKeys, keys.UpdateChannel) {
return
}

// No change
// No change -- this is the only setting we currently care about.
if ta.updateChannel == ta.knapsack.UpdateChannel() {
return
}
Expand Down

0 comments on commit 001ee97

Please sign in to comment.