From d77d68753cc68caf632c2858ba5217451ae0bb07 Mon Sep 17 00:00:00 2001 From: git-sid <25916907+git-sid@users.noreply.github.com> Date: Thu, 13 Sep 2018 19:54:51 +0200 Subject: [PATCH] WIP: #31 fix: blacklist -> blocklist. Replace all relevant instances of "blacklist" with blocklist. Untested due to OS restricitions. Please check before merge. --- README.md | 6 +++--- frontend.py | 4 ++-- static/bot.html | 10 +++++----- static/js/functions.js | 2 +- template/settings.tpl | 10 +++++----- user.py | 2 +- 6 files changed, 17 insertions(+), 17 deletions(-) diff --git a/README.md b/README.md index da364b7..fcc2933 100644 --- a/README.md +++ b/README.md @@ -50,16 +50,16 @@ to check if something was retweeted in the last hour or something. To this date, we have never heard of this happening though. -### blacklisting +### blockisting -You also need to edit the goodlist and the blacklist. You can do this on the +You also need to edit the goodlist and the blocklist. You can do this on the website, in the settings of your bot. Just add the words to the goodlist, which you want to require. A report is only spread if it contains at least one of them. If you want to RT everything, just add a ```*```. -There is also a blacklist, which you can use to automatically sort out +There is also a blocklist, which you can use to automatically sort out malicious messages. Be careful though, our filter can't read the intention with which a word was used. Maybe you wanted it there. diff --git a/frontend.py b/frontend.py index 45a1981..ca8264a 100755 --- a/frontend.py +++ b/frontend.py @@ -153,10 +153,10 @@ def update_trigger_patterns(user): return user.state() -@post('/settings/blacklist') +@post('/settings/blocklist') @view('template/settings.tpl') def update_badwords(user): - user.set_badwords(request.forms['blacklist']) + user.set_badwords(request.forms['blocklist']) return user.state() diff --git a/static/bot.html b/static/bot.html index 9d11d2f..b2e2bf6 100644 --- a/static/bot.html +++ b/static/bot.html @@ -83,16 +83,16 @@ - +

These words are not allowed in reports. If you encounter spam, you can add more here - the bot will ignore reports which use such words. - +

-
- - + + +
diff --git a/static/js/functions.js b/static/js/functions.js index ef1fa5c..4630ae0 100644 --- a/static/js/functions.js +++ b/static/js/functions.js @@ -36,4 +36,4 @@ document.getElementById("enablebutton").innerHTML = enableButton(); document.getElementById("goodlist").innerHTML = listformat(getCookie("goodlist")); -document.getElementById("blacklist").innerHTML = listformat(getCookie("blacklist")); \ No newline at end of file +document.getElementById("blocklist").innerHTML = listformat(getCookie("blocklist")); \ No newline at end of file diff --git a/template/settings.tpl b/template/settings.tpl index acc2b5e..234128d 100644 --- a/template/settings.tpl +++ b/template/settings.tpl @@ -140,15 +140,15 @@
-

Edit the blacklist

+

Edit the blocklist

These words are not allowed in reports. If you encounter spam, you can add more here - the bot will ignore reports which use such words. - - +

+ +
diff --git a/user.py b/user.py index 2e1a550..4487f4e 100644 --- a/user.py +++ b/user.py @@ -253,7 +253,7 @@ schlitz # - markdown # - mail_md # - goodlist - # - blacklist + # - blocklist # - logged in with twitter? # - logged in with mastodon? # - enabled?