From 547f811ee74d4bee6ddcfab9489690f258f7ac4b Mon Sep 17 00:00:00 2001 From: Till Skrodzki Date: Sun, 21 Jan 2024 09:28:13 +0100 Subject: [PATCH] Serialize JSON with b64 encoding/decoding for data field of LatestMitmDataEntry.py --- .../mitm_data/holder/latest_mitm_data/LatestMitmDataEntry.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mapadroid/data_handler/mitm_data/holder/latest_mitm_data/LatestMitmDataEntry.py b/mapadroid/data_handler/mitm_data/holder/latest_mitm_data/LatestMitmDataEntry.py index c343f07a4..6ad9f4e44 100644 --- a/mapadroid/data_handler/mitm_data/holder/latest_mitm_data/LatestMitmDataEntry.py +++ b/mapadroid/data_handler/mitm_data/holder/latest_mitm_data/LatestMitmDataEntry.py @@ -52,5 +52,5 @@ async def from_json(json_data: Union[bytes, str]) -> Optional[LatestMitmDataEntr async def to_json(self) -> bytes: if isinstance(self.data, bytes): - self.data = base64.b64encode(self.data) + self.data = str(base64.b64encode(self.data)) return orjson.dumps(self.__dict__)