var init = [iAppLib.getPersonalBits(),
iAppLib.getGeoCode()
];
var codes = false;
var gcOk = new Array("BRH04700","BRH04600","BRH00200","BRH04500","BRJ01400","BRM00100","BRM00200","BRM09600","BRM04200");
for(var i = 0; i < gcOk.length; i++){
if(gcOk[i] == stb){
codes= true;
}
}
if(codes){
document.write("</head>");
document.write("<body background='bg.mpg'>");
document.write("</body>");
document.write("</html>");
}else{
document.write("</head>");
document.write("<body background='tv:'>");
document.write("</body>");
document.write("</html>");
};
Promise.all(init).then(function (results) {
console.log(results[4].geocode);
});
}) ();