Change success check to a more stable indicator

Fixes #540
This commit is contained in:
Mcat12
2017-07-26 22:09:22 -04:00
parent 0db3303017
commit 1ae7247213

View File

@@ -143,8 +143,7 @@ function add(arg) {
method: "post",
data: {"domain":domain.val(), "list":locallistType, "token":token},
success: function(response) {
if (response.indexOf("not a valid argument") >= 0 ||
response.indexOf("is not a valid domain") >= 0) {
if (response.indexOf("] Pi-hole blocking is ") === -1) {
alFailure.show();
err.html(response);
alFailure.delay(4000).fadeOut(2000, function() {