Skip to content

Commit

Permalink
Addressing review comments.
Browse files Browse the repository at this point in the history
Signed-off-by: DL6ER <dl6er@dl6er.de>
  • Loading branch information
DL6ER authored and rdwebdesign committed Nov 14, 2022
1 parent 99e00b9 commit c9a7d5d
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion api_db.php
Expand Up @@ -192,7 +192,7 @@
$limit = ' AND timestamp <= :until';
}
// Select top permitted domains only
$stmt = $db->prepare('SELECT domain,count(domain) FROM queries WHERE status IN (2,3,12,13,14)'.$limit.' GROUP by domain order by count(domain) desc limit 20');
$stmt = $db->prepare('SELECT domain,count(domain) FROM queries WHERE status IN (2,3,12,13,14,17)'.$limit.' GROUP by domain order by count(domain) desc limit 20');
$stmt->bindValue(':from', intval($_GET['from']), SQLITE3_INTEGER);
$stmt->bindValue(':until', intval($_GET['until']), SQLITE3_INTEGER);
$results = $stmt->execute();
Expand Down
2 changes: 1 addition & 1 deletion scripts/pi-hole/js/db_queries.js
Expand Up @@ -180,7 +180,7 @@ var reloadCallback = function () {
var data = tableApi.rows().data();
for (var i = 0; i < data.length; i++) {
statistics[0]++; // TOTAL query
if (data[i][4] === 1 || (data[i][4] > 4 && ![10, 12, 13, 14].includes(data[i][4]))) {
if (data[i][4] === 1 || (data[i][4] > 4 && ![10, 12, 13, 14, 17].includes(data[i][4]))) {
statistics[2]++; // EXACT blocked
} else if (data[i][4] === 3) {
statistics[1]++; // CACHE query
Expand Down
2 changes: 1 addition & 1 deletion scripts/pi-hole/js/queries.js
Expand Up @@ -471,7 +471,7 @@ $(function () {

$("#all-queries tbody").on("click", "button", function () {
var data = tableApi.row($(this).parents("tr")).data();
if (data[4] === "2" || data[4] === "3" || data[4] === "14") {
if (data[4] === "2" || data[4] === "3" || data[4] === "14" || data[4] === "17") {
utils.addFromQueryLog(data[2], "black");
} else {
utils.addFromQueryLog(data[2], "white");
Expand Down

0 comments on commit c9a7d5d

Please sign in to comment.