Driver not scheduling

I nicked a bit of code from an example of an existing driver, and it could set a schedule for a refresh of data from a url.
On my production hub, this works like a charm.

Now another user wanted to use the driver, but it did not set a scedule. So as a test I placed the driver on my develop / test hub, and indeed it dos not schedule.

What am I doing wrong?

The complete driver here

Sniplet that defines the scheduling:

if (enablePoll) {

	Integer interval = Integer.parseInt(settings.pollInterval)
	
	switch (interval) {
		case 1: 
			runEvery1Minute(refresh)
			break
		case 5:
			runEvery5Minutes(refresh)
			break
		case 10:
			runEvery10Minutes(refresh)
			break
		case 15:
			runEvery15Minutes(refresh)
			break
		case 30:
			runEvery30Minutes(refresh)
			break
		case 60:
			runEvery1Hour(refresh)
			break
		case 180:
			runEvery3Hours(refresh)
			break
		default:
			runIn(interval*60,refresh)
			break
	}
input name: "enablePull"

does not equal

 if (enablePoll) {

"u" vs "o"

3 Likes

I also suggest some logs to confirm what @JasonJoel is referring to... Even as debug logs that are controlled via a switch in the preferences to turn them on / off....

Indeed, I am a total dumbass..... Wel that was embarrassing...

Thank you :wink:

1 Like

We've all been there... trust me.... haven't we....?

2 Likes

I've done the same thing maybe a zillion times (or at least what feels like a zillion times). No judgement on my end. lol

3 Likes

Don't worry, we won't tell anyone....

1 Like

At my work, this would now be on a A0 sized poster in the pantry... :slight_smile:

1 Like

Here you just get a publicly available post detailing the oversight.... :slight_smile:

2 Likes

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.