From 12148a48c69a9c44d9caa8d586b845d4c6ad3494 Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Tue, 27 Oct 2020 20:10:02 +0000 Subject: [PATCH] Fix condition --- daemon.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/daemon.py b/daemon.py index a647650fc..74337cc44 100644 --- a/daemon.py +++ b/daemon.py @@ -9434,9 +9434,12 @@ class PubServer(BaseHTTPRequestHandler): 'permitted directory', 'login shown done') - if htmlGET and '/users/' in self.path and \ + if htmlGET and self.path.startswith('/users/') and \ self.path.endswith('/newswiremobile'): - if (authorized or (not authorized and '/users/news/' in self.path)): + if (authorized or + (not authorized and + self.path.startswith('/users/news/') and + self.server.newsInstance)): nickname = getNicknameFromActor(self.path) if not nickname: self._404()