index.js
function crawlScript($,result, script, callback) {

    var link = $(script).attr('src');
    var parentUrl = result.url;

    if (link) {
          var linkUri = URI.linkToURI(parentUrl, link);
          pm.crawlLink(parentUrl, linkUri, null, null, function(){
            addLinkToQueue(result, parentUrl, linkUri, null, null, callback);
          });
    }
    else {
      callback();
    }


}
function crawlScript($,result, script, callback) {

    var link = $(script).attr('src');
    var parentUrl = result.url;

    if (link) {
          var linkUri = URI.linkToURI(parentUrl, link);
          pm.crawlLink(parentUrl, linkUri, null, null, function(){
            addLinkToQueue(result, parentUrl, linkUri, null, null, callback);
          });
    }
    else {
      callback();
    }


}
function crawlScript ( $ , result , script , callback ) { var link = $ ( script ) . attr ( 'src' ) ; var parentUrl = result . url ; if ( link ) { var linkUri = URI . linkToURI ( parentUrl , link ) ; pm . crawlLink ( parentUrl , linkUri , null , null , function ( ) { addLinkToQueue ( result , parentUrl , linkUri , null , null , callback ) ; } ) ; } else { callback ( ) ; } }
Extract info of script tag & send the info to the plugins


@param The HTML body containing the script tag (Cheerio wraper)
@param The http response with the crawl options
@param The script tag
@param callback()
Extract info of script tag & send the info to the plugins