Remove special error case for Brave browser (#1618)

Reverts b7e1261597
This commit is contained in:
Anton Lazarev 2020-10-20 01:37:02 -04:00 committed by GitHub
parent fb21124c9e
commit 8e1f79f537
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 6 deletions

View File

@ -33,6 +33,7 @@ public class Contributors {
public static String generateContributorHtml() {
Contributor[] contributors = new Contributor[]{
new Contributor("aidn5", CODE),
new Contributor("Antonok", CODE),
new Contributor("Argetan", CODE),
new Contributor("Aurelien", CODE, LANG),
new Contributor("BrainStone", CODE),

View File

@ -24,12 +24,7 @@ function jsonRequest(address, callback) {
callback(null, "Request did not reach the server. (Server offline / Adblocker?)")
}
} catch (e) {
if (e.message.includes('Unexpected end of JSON input') && navigator.brave && navigator.brave.isBrave) {
navigator.brave.isBrave()
.then(confirm => callback(null, e.message + (confirm ? " (Possibly blocked by ad-block in Brave)" : '') + " (See " + address + ")"));
} else {
callback(null, e.message + " (See " + address + ")")
}
callback(null, e.message + " (See " + address + ")")
}
}
};