diff --git a/src/sempy_labs/report/_reportwrapper.py b/src/sempy_labs/report/_reportwrapper.py index f20bffce..3d1e81ed 100644 --- a/src/sempy_labs/report/_reportwrapper.py +++ b/src/sempy_labs/report/_reportwrapper.py @@ -1332,6 +1332,7 @@ def set_theme(self, theme_file_path: str): theme_name = json_file["name"] theme_name_full = f"{theme_name}.json" + rd = self.rdef # Add theme.json file to request_body file_payload = _conv_b64(json_file) @@ -1345,11 +1346,12 @@ def set_theme(self, theme_file_path: str): "type": "CustomTheme", } - rd = self.rdef for _, r in rd.iterrows(): path = r["path"] payload = r["payload"] - if path != report_path: + if path == filePath: + pass + elif path != report_path: _add_part(request_body, path, payload) # Update the report.json file else: