mirror of https://gitlab.com/bashrc2/epicyon
Updating enabled cw lists
parent
2ad58b798e
commit
88c4b14ca3
|
|
@ -5696,9 +5696,7 @@ class PubServer(BaseHTTPRequestHandler):
|
|||
except BaseException:
|
||||
pass
|
||||
|
||||
# save blocked user agents
|
||||
# This is admin lebel and global to the instance
|
||||
if path.startswith('/users/' + adminNickname + '/'):
|
||||
if isModerator(self.server.baseDir, nickname):
|
||||
# set selected content warning lists
|
||||
newListsEnabled = ''
|
||||
for name, item in self.server.CWlists.items():
|
||||
|
|
@ -5715,6 +5713,7 @@ class PubServer(BaseHTTPRequestHandler):
|
|||
"listsEnabled",
|
||||
newListsEnabled)
|
||||
|
||||
# save blocked user agents
|
||||
userAgentsBlocked = []
|
||||
if fields.get('userAgentsBlockedStr'):
|
||||
userAgentsBlockedStr = \
|
||||
|
|
|
|||
|
|
@ -34,6 +34,7 @@ from person import personBoxJson
|
|||
from person import getActorJson
|
||||
from person import getPersonAvatarUrl
|
||||
from webfinger import webfingerHandle
|
||||
from posts import isModerator
|
||||
from posts import parseUserFeed
|
||||
from posts import getPersonBox
|
||||
from posts import isCreateInsideAnnounce
|
||||
|
|
@ -1667,6 +1668,7 @@ def _htmlEditProfileFiltering(baseDir: str, nickname: str, domain: str,
|
|||
'style="height:200px" spellcheck="false">' + \
|
||||
allowedInstancesStr + '</textarea>\n'
|
||||
|
||||
if isModerator(baseDir, nickname):
|
||||
userAgentsBlockedStr = ''
|
||||
for ua in userAgentsBlocked:
|
||||
if userAgentsBlockedStr:
|
||||
|
|
|
|||
Loading…
Reference in New Issue