diff --git a/internal/action/redo.go b/internal/action/redo.go index be58f05..317ed86 100644 --- a/internal/action/redo.go +++ b/internal/action/redo.go @@ -36,7 +36,7 @@ func NewRedo( } func (r *Redo) Run(ctx *cli.Context) error { - limit, err := args.ParseStepStringOrDefault(ctx.Args().Get(0), 1) + limit, err := args.ParseStepStringOrDefault(ctx.Args().Get(0), minLimit) if err != nil { return err } diff --git a/internal/action/upgrade.go b/internal/action/upgrade.go index f25e63c..3883680 100644 --- a/internal/action/upgrade.go +++ b/internal/action/upgrade.go @@ -15,6 +15,10 @@ import ( "github.com/urfave/cli/v2" ) +const ( + defaultUpgradeLimit = 0 +) + type Upgrade struct { console Console service MigrationService @@ -37,7 +41,7 @@ func NewUpgrade( } func (u *Upgrade) Run(ctx *cli.Context) error { - limit, err := args.ParseStepStringOrDefault(ctx.Args().Get(0), minLimit) + limit, err := args.ParseStepStringOrDefault(ctx.Args().Get(0), defaultUpgradeLimit) if err != nil { return err }