Merge pull request #623 from pi-hole/release-3.2-codacyfixes

Code style fixes for Pi-hole v3.2 release
This commit is contained in:
Adam Warner
2017-12-07 00:52:21 +00:00
committed by GitHub
+14 -14
View File
@@ -3,7 +3,7 @@
* Network-wide ad blocking via your own hardware.
*
* This file is copyright under the latest version of the EUPL.
* Please see LICENSE file for your rights under this license. */
* Please see LICENSE file for your rights under this license. */
var tableApi;
function escapeRegex(text) {
@@ -189,24 +189,24 @@ $(document).ready(function() {
"initComplete": function () {
var api = this.api();
// Query type IPv4 / IPv6
api.$('td:eq(1)').click( function () { api.search( this.innerHTML ).draw(); $('#resetButton').show(); } );
api.$('td:eq(1)').hover(
function () { this.title="Click to show only "+this.innerHTML+" queries"; this.style.color="#72afd2" },
function () { this.style.color="" }
api.$("td:eq(1)").click( function () { api.search( this.innerHTML ).draw(); $("#resetButton").show(); } );
api.$("td:eq(1)").hover(
function () { this.title="Click to show only "+this.innerHTML+" queries"; this.style.color="#72afd2"; },
function () { this.style.color=""; }
);
api.$("td:eq(1)").css("cursor","pointer");
// Domain
api.$('td:eq(2)').click( function () { api.search( this.innerHTML ).draw(); $('#resetButton').show(); } );
api.$('td:eq(2)').hover(
function () { this.title="Click to show only queries with domain "+this.innerHTML; this.style.color="#72afd2" },
function () { this.style.color="" }
api.$("td:eq(2)").click( function () { api.search( this.innerHTML ).draw(); $("#resetButton").show(); } );
api.$("td:eq(2)").hover(
function () { this.title="Click to show only queries with domain "+this.innerHTML; this.style.color="#72afd2"; },
function () { this.style.color=""; }
);
api.$("td:eq(2)").css("cursor","pointer");
// Client
api.$('td:eq(3)').click( function () { api.search( this.innerHTML ).draw(); $('#resetButton').show(); } );
api.$('td:eq(3)').hover(
function () { this.title="Click to show only queries made by "+this.innerHTML; this.style.color="#72afd2" },
function () { this.style.color="" }
api.$("td:eq(3)").click( function () { api.search( this.innerHTML ).draw(); $("#resetButton").show(); } );
api.$("td:eq(3)").hover(
function () { this.title="Click to show only queries made by "+this.innerHTML; this.style.color="#72afd2"; },
function () { this.style.color=""; }
);
api.$("td:eq(3)").css("cursor","pointer");
}
@@ -224,7 +224,7 @@ $(document).ready(function() {
}
} );
$('#resetButton').click( function () { tableApi.search("").draw(); $('#resetButton').hide(); } );
$("#resetButton").click( function () { tableApi.search("").draw(); $("#resetButton").hide(); } );
} );