Skip to content

Commit

Permalink
rename timeout job to sleep to avoid confusion
Browse files Browse the repository at this point in the history
  • Loading branch information
arriven committed Apr 4, 2022
1 parent ccecdf8 commit 21206e1
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/job/base.go
Original file line number Diff line number Diff line change
Expand Up @@ -105,8 +105,8 @@ func Get(t string) Job {
return setVarJob
case "check":
return checkJob
case "timeout":
return timeoutJob
case "sleep":
return sleepJob
case "loop":
return loopJob
case "discard-error":
Expand Down
2 changes: 1 addition & 1 deletion src/job/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ func checkJob(ctx context.Context, logger *zap.Logger, _ *GlobalConfig, args con
return nil, nil
}

func timeoutJob(ctx context.Context, logger *zap.Logger, _ *GlobalConfig, args config.Args) (data any, err error) {
func sleepJob(ctx context.Context, logger *zap.Logger, _ *GlobalConfig, args config.Args) (data any, err error) {
var jobConfig struct {
Value time.Duration
}
Expand Down

0 comments on commit 21206e1

Please sign in to comment.