mirror of
https://github.com/pi-hole/web.git
synced 2025-12-24 20:55:28 +00:00
Fix .context usage in our code
Signed-off-by: XhmikosR <xhmikosr@gmail.com>
This commit is contained in:
@@ -131,18 +131,20 @@ $(function () {
|
||||
// Pull in data via AJAX
|
||||
updateTopLists();
|
||||
|
||||
$("#domain-frequency tbody").on("click", "button", function () {
|
||||
$("#domain-frequency tbody").on("click", "button", function (event) {
|
||||
var url = $(this).parents("tr")[0].textContent.split(" ")[0];
|
||||
if ($(this).context.textContent === " Blacklist") {
|
||||
|
||||
if (event.target.textContent.trim() === "Blacklist") {
|
||||
blacklistUrl(url);
|
||||
} else {
|
||||
auditUrl(url);
|
||||
}
|
||||
});
|
||||
|
||||
$("#ad-frequency tbody").on("click", "button", function () {
|
||||
$("#ad-frequency tbody").on("click", "button", function (event) {
|
||||
var url = $(this).parents("tr")[0].textContent.split(" ")[0];
|
||||
if ($(this).context.textContent === " Whitelist") {
|
||||
|
||||
if (event.target.textContent.trim() === "Whitelist") {
|
||||
whitelistUrl(url);
|
||||
} else {
|
||||
auditUrl(url);
|
||||
|
||||
Reference in New Issue
Block a user