Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix issue with "Scheduled" panics when job not scheduled #155

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

ferryvg
Copy link

@ferryvg ferryvg commented Apr 20, 2020

#129 issue

This code are panics:

func One() {}
func Two() {}
func main() {
	scheduler := gocron.NewScheduler()
	scheduler.Every(1).Day().Do(One)
	// and next panics
	exists := scheduler.Scheduled(Two)
	fmt.Println(exists)
}

@ferryvg ferryvg changed the title Fix issue with Scheduled panic for not found jobs Fix issue with Scheduled panics when job not scheduled Apr 20, 2020
@ferryvg ferryvg changed the title Fix issue with Scheduled panics when job not scheduled Fix issue withScheduled panics when job not scheduled Apr 20, 2020
@ferryvg ferryvg changed the title Fix issue withScheduled panics when job not scheduled Fix issue with "Scheduled" panics when job not scheduled Apr 20, 2020
@ferryvg ferryvg marked this pull request as ready for review April 20, 2020 08:17
@JohnRoesler
Copy link
Contributor

hey, this repo is no longer maintained (per the note in the readme) - we have a maintained fork over at https://github.com/go-co-op/gocron and recently added support for this exact use! go-co-op/gocron#106

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants