diff --git a/nodes/core/20-inject.html b/nodes/core/20-inject.html index 8ab75445b..a4c46ede1 100644 --- a/nodes/core/20-inject.html +++ b/nodes/core/20-inject.html @@ -202,7 +202,7 @@ }, oneditprepare: function() { var repeattype = "none"; - if (Number(this.repeat) != 0) { + if (parseInt(this.repeat) != 0) { repeattype = "interval"; $("#inject-time-interval-units option").filter(function() {return $(this).val() == "s";}).attr('selected',true); $("#inject-time-interval-count").val(this.repeat); @@ -210,7 +210,7 @@ } else if (this.crontab) { var cronparts = this.crontab.split(" "); var days = cronparts[4]; - if (Number(cronparts[0]) && Number(cronparts[1])) { + if (!isNaN(cronparts[0]) && !isNaN(cronparts[1])) { repeattype = "time"; // Fixed time var time = cronparts[1]+":"+cronparts[0];