Skip to content

Commit

Permalink
fix(iro): get tradable plans filter (#1546)
Browse files Browse the repository at this point in the history
  • Loading branch information
zale144 authored Nov 25, 2024
1 parent 93b6385 commit f3252be
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion x/iro/keeper/iro.go
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ func (k Keeper) GetAllPlans(ctx sdk.Context, tradableOnly bool) (list []types.Pl
for ; iterator.Valid(); iterator.Next() {
var val types.Plan
k.cdc.MustUnmarshal(iterator.Value(), &val)
if tradableOnly && !val.IsSettled() && !val.StartTime.After(ctx.BlockTime()) {
if tradableOnly && (val.IsSettled() || val.StartTime.After(ctx.BlockTime())) {
continue
}
list = append(list, val)
Expand Down

0 comments on commit f3252be

Please sign in to comment.