From 0879104d40fcf79ebdeada97e69a62f025ebd019 Mon Sep 17 00:00:00 2001 From: Dave Astels Date: Mon, 15 Jul 2019 18:01:48 -0400 Subject: [PATCH] Add set_headers --- adafruit_pyportal.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/adafruit_pyportal.py b/adafruit_pyportal.py index dbaa922..0c0614a 100644 --- a/adafruit_pyportal.py +++ b/adafruit_pyportal.py @@ -362,6 +362,13 @@ def __init__(self, *, url=None, headers=None, json_path=None, regexp_path=None, gc.collect() + def set_headers(self, headers): + """Set the headers used by fetch(). + + :param headers: The new header dictionary + """ + self._headers = headers + def set_background(self, file_or_color, position=None): """The background image to a bitmap file.