mirror of
https://github.com/kemko/nomad.git
synced 2026-01-08 19:35:41 +03:00
3
.changelog/13845.txt
Normal file
3
.changelog/13845.txt
Normal file
@@ -0,0 +1,3 @@
|
||||
```release-note:bug
|
||||
api: Fixed a nil pointer dereference when periodic jobs are missing their periodic spec
|
||||
```
|
||||
@@ -822,7 +822,7 @@ func (p *PeriodicConfig) Canonicalize() {
|
||||
// returned. The `time.Location` of the returned value matches that of the
|
||||
// passed time.
|
||||
func (p *PeriodicConfig) Next(fromTime time.Time) (time.Time, error) {
|
||||
if *p.SpecType == PeriodicSpecCron {
|
||||
if p != nil && *p.SpecType == PeriodicSpecCron {
|
||||
e, err := cronexpr.Parse(*p.Spec)
|
||||
if err != nil {
|
||||
return time.Time{}, fmt.Errorf("failed parsing cron expression %q: %v", *p.Spec, err)
|
||||
|
||||
Reference in New Issue
Block a user