From 97c2a32869b84061bc1a933b1639cdc9c19d1865 Mon Sep 17 00:00:00 2001 From: Pawel Date: Mon, 15 Apr 2024 23:21:28 -0700 Subject: [PATCH] correct algo --- rollbar/lib/transforms/shortener.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/rollbar/lib/transforms/shortener.py b/rollbar/lib/transforms/shortener.py index 8685429d..ae8d810b 100644 --- a/rollbar/lib/transforms/shortener.py +++ b/rollbar/lib/transforms/shortener.py @@ -82,7 +82,9 @@ def traverse_dict(self, d): d = self._shorten_mapping(d, max_size) for k, v in d.items(): if isinstance(v, dict): - self.traverse_dict(v) + max_size = self._get_max_size(v) + d[k] = self._shorten_mapping(v, max_size) + self.traverse_dict(d[k]) else: d[k] = self._shorten(v) return d