code: function (zaproxy, statusFn, callback) {
      var wait = function () {
        statusFn(function (err, body) {
          if (err) {
            callback(err);
            return;
          }
          if (body.status < 100) {
            grunt.log.write('.');
            setTimeout(function () {
              wait(callback);
            }, 1000);
          } else {
            callback(null, body);
          }
        });
      };
      wait();
    }
docs: Wait for a scan to finish.