mirror of
https://gitlab.com/crafty-controller/crafty-4.git
synced 2024-08-30 18:23:09 +00:00
Fix & with bleach
This commit is contained in:
parent
1b2fef06fb
commit
df7d10886e
@ -104,7 +104,7 @@ class BaseHandler(tornado.web.RequestHandler):
|
||||
strip: bool = True,
|
||||
) -> t.Optional[str]:
|
||||
arg = self._get_argument(name, default, self.request.arguments, strip)
|
||||
return self.autobleach(name, arg)
|
||||
return self.autobleach(name, arg).replace("&", "&")
|
||||
|
||||
def get_arguments(self, name: str, strip: bool = True) -> t.List[str]:
|
||||
if not isinstance(strip, bool):
|
||||
|
@ -1727,7 +1727,7 @@ class PanelHandler(BaseHandler):
|
||||
if interval_type == "days":
|
||||
sch_time = bleach.clean(self.get_argument("time", None))
|
||||
if action == "command":
|
||||
command = bleach.clean(self.get_argument("command", None))
|
||||
command = self.get_argument("command", None)
|
||||
elif action == "start":
|
||||
command = "start_server"
|
||||
elif action == "stop":
|
||||
@ -1743,7 +1743,7 @@ class PanelHandler(BaseHandler):
|
||||
delay = bleach.clean(self.get_argument("delay", None))
|
||||
parent = bleach.clean(self.get_argument("parent", None))
|
||||
if action == "command":
|
||||
command = bleach.clean(self.get_argument("command", None))
|
||||
command = self.get_argument("command", None)
|
||||
elif action == "start":
|
||||
command = "start_server"
|
||||
elif action == "stop":
|
||||
@ -1763,7 +1763,7 @@ class PanelHandler(BaseHandler):
|
||||
return
|
||||
action = bleach.clean(self.get_argument("action", None))
|
||||
if action == "command":
|
||||
command = bleach.clean(self.get_argument("command", None))
|
||||
command = self.get_argument("command", None)
|
||||
elif action == "start":
|
||||
command = "start_server"
|
||||
elif action == "stop":
|
||||
@ -1889,7 +1889,7 @@ class PanelHandler(BaseHandler):
|
||||
if interval_type == "days":
|
||||
sch_time = bleach.clean(self.get_argument("time", None))
|
||||
if action == "command":
|
||||
command = bleach.clean(self.get_argument("command", None))
|
||||
command = self.get_argument("command", None)
|
||||
elif action == "start":
|
||||
command = "start_server"
|
||||
elif action == "stop":
|
||||
@ -1904,7 +1904,7 @@ class PanelHandler(BaseHandler):
|
||||
delay = bleach.clean(self.get_argument("delay", None))
|
||||
parent = bleach.clean(self.get_argument("parent", None))
|
||||
if action == "command":
|
||||
command = bleach.clean(self.get_argument("command", None))
|
||||
command = self.get_argument("command", None)
|
||||
elif action == "start":
|
||||
command = "start_server"
|
||||
elif action == "stop":
|
||||
@ -1924,7 +1924,7 @@ class PanelHandler(BaseHandler):
|
||||
return
|
||||
action = bleach.clean(self.get_argument("action", None))
|
||||
if action == "command":
|
||||
command = bleach.clean(self.get_argument("command", None))
|
||||
command = self.get_argument("command", None)
|
||||
elif action == "start":
|
||||
command = "start_server"
|
||||
elif action == "stop":
|
||||
|
Loading…
Reference in New Issue
Block a user