From 3d3486c266b33f6d21d51c9d414e3fb359ea3803 Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Sat, 24 Aug 2019 12:25:34 +0100 Subject: [PATCH] Accept header for images --- daemon.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/daemon.py b/daemon.py index 1e2fb0a1..a316de70 100644 --- a/daemon.py +++ b/daemon.py @@ -145,6 +145,8 @@ class PubServer(BaseHTTPRequestHandler): def _requestHTTP(self) -> bool: """Should a http response be given? """ + if self.headers['Accept'].startswith('*'): + return True if 'json' in self.headers['Accept']: return False return True