Ensure the callback function exists before calling

This commit is contained in:
Steve Beaver 2017-08-09 14:19:29 -04:00
parent 8bf4cf1f14
commit e78d59403b

View File

@ -665,7 +665,7 @@ events.push(function() {
var freq = ajaxspecs[ajaxidx].freq; // widget can specifify it should be called freq times around hte loop
if (!ajaxmutex) {
if ((ajaxcntr % freq) === 0) {
if (((ajaxcntr % freq) === 0) && (typeof ajaxspecs[ajaxidx].callback === "function" )) {
make_ajax_call(ajaxspecs[ajaxidx]);
}