Skip to content

Commit

Permalink
typo
Browse files Browse the repository at this point in the history
  • Loading branch information
leonz789 committed Jan 20, 2025
1 parent c411047 commit b4a76c4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 1 addition & 1 deletion x/oracle/keeper/feedermanagement/feedermanager.go
Original file line number Diff line number Diff line change
Expand Up @@ -657,7 +657,7 @@ func (f *FeederManager) ProcessQuote(ctx sdk.Context, msg *oracletypes.MsgCreate
r, ok := f.rounds[int64(msgItem.FeederID)]
if !ok {
// This should not happened since we do check the nonce in anthHandle
return nil, fmt.Errorf("round not exists for feederID:%d, porposer:%s", msgItem.FeederID, msgItem.Validator)
return nil, fmt.Errorf("round not exists for feederID:%d, proposer:%s", msgItem.FeederID, msgItem.Validator)
}

// #nosec G115 // baseBlock is block height which is not negative
Expand Down
3 changes: 3 additions & 0 deletions x/oracle/keeper/feedermanagement/prices.go
Original file line number Diff line number Diff line change
Expand Up @@ -300,6 +300,9 @@ func (ps *priceSource) Add(psNew *priceSource) (*priceSource, error) {
}

if !ps.deterministic {
if len(psNew.prices) == 0 {
return nil, errors.New("failed to add ProtoPriceSource for NS, psNew.prices is empty")
}
// this is not ds, then just set the final price or overwrite if the input has a later timestamp
if ps.finalPrice == nil {
ps.finalPrice = psNew.prices[0].PriceResult()
Expand Down

0 comments on commit b4a76c4

Please sign in to comment.