Fix for calling an undefined function in case cb is not set.