Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
function complete(error,response,data)
{
var parser=new expat.parser(); // new instance of parser
//console.log(profileurl);
//console.log(data);
parser.parse(data);
var specs=parser.root;
if(specs.RDF)
{
// array to object implementation:
if(!(specs.RDF instanceof Array)&&specs.RDF.Description)
{
specs.RDF=[specs.RDF.Description];
}
for(var n=0,j=specs.RDF.length;n
require('fs').readFile(__dirname+'/wurfl-latest.xml', 'utf-8',function (err, data) {
if (err) throw err;
var xmlparser=new expat.parser();
xmlparser.parse(data);
self.data=xmlparser.root;
callback();
});
}this.loadxml=loadxml;