Skip to content

Commit

Permalink
Stop paginating after finding a matching parameter.
Browse files Browse the repository at this point in the history
  • Loading branch information
jmcarp committed Sep 3, 2018
1 parent 115e29b commit 0134e37
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion store/ssmstore.go
Original file line number Diff line number Diff line change
Expand Up @@ -221,9 +221,10 @@ func (s *SSMStore) readLatest(id SecretId) (Secret, error) {
for _, param := range o.Parameters {
if *param.Name == s.idToName(id) {
parameter = param
return false
}
}
return !lastPage
return true
}); err != nil {
return Secret{}, err
}
Expand Down

0 comments on commit 0134e37

Please sign in to comment.