Merge pull request #1436 from craiglondon/VariableDeclaration

Fix declaration of some variables
main
Elbert Alias 8 years ago committed by GitHub
commit 0ba426d578

@ -9,7 +9,7 @@
var
w = wappalyzer,
debug = true
debug = true,
d = window.document,
container = d.getElementById('wappalyzer-container'),
domain = window.top.location.host,

@ -1,9 +1,8 @@
document.addEventListener('DOMContentLoaded', function() {
var
i, value,
d = document
nodes = d.getElementsByTagName('*')
;
d = document,
nodes = d.getElementsByTagName('*');
for ( i = 0; i < nodes.length; i ++ ) {
if ( attr = nodes[i].dataset.i18n ) {

@ -1,6 +1,7 @@
(function() {
try {
var i, environmentVars, e = document.createEvent('Events');
var i, environmentVars,
e = document.createEvent('Events');
e.initEvent('wappalyzerEvent', true, false);

@ -37,7 +37,7 @@ document.addEventListener('DOMContentLoaded', function() {
confidence = response.tabCache.appsDetected[appName].confidenceTotal;
version = response.tabCache.appsDetected[appName].version;
html =
var html =
'<div class="detected-app">' +
'<a target="_blank" href="https://wappalyzer.com/applications/' + slugify(appName) + '?pk_campaign=chrome&pk_kwd=popup">' +
'<img src="images/icons/' + response.apps[appName].icon + '"/>' +

@ -1,7 +1,7 @@
(function() {
self.port.on('displayApps', function(message) {
var
div, a, img, label, name, slugify,
div, a, img, label, name, slugify, confidence, version,
d = document,
detectedApps = d.getElementById('detected-apps'),
empty = d.getElementById('empty');
@ -52,8 +52,8 @@
label.appendChild(name);
label.appendChild(d.createTextNode(( version ? ' ' + version : '' ) + ( confidence < 100 ? ' (' + confidence + '% sure)' : '')));
a.appendChild(img)
a.appendChild(label)
a.appendChild(img);
a.appendChild(label);
div.appendChild(a);

@ -4,8 +4,8 @@
try {
if ( document && document.contentType === 'text/html' ) {
var
html = new XMLSerializer().serializeToString(document)
env = [];
html = new XMLSerializer().serializeToString(document),
env = []; // TODO: Remove, `env` not used in this scope?
self.port.emit('log', html);

@ -5,8 +5,8 @@
scriptDir,
scriptPath = require('fs').absolute(require('system').args[0]),
resourceTimeout = 9000,
args = [],
debug = false; // Output debug messages
args = [], // TODO: Not used, maybe should be `arg`
debug = false, // Output debug messages
quiet = false; // Don't output errors
try {

Loading…
Cancel
Save