Skip to content

Commit 88966cb

Browse files
Merge pull request #989 from gooddata/snapshot-master-c80fd373-to-rel/dev
[bot] Merge master/c80fd373 into rel/dev
2 parents cda8253 + c80fd37 commit 88966cb

File tree

1 file changed

+4
-1
lines changed
  • gooddata-sdk/gooddata_sdk/catalog/export

1 file changed

+4
-1
lines changed

gooddata-sdk/gooddata_sdk/catalog/export/service.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,10 @@ def export_pdf(
214214
if not self._dashboard_id_exists(workspace_id, dashboard_id):
215215
raise ValueError(f"Dashboard id '{dashboard_id}' does not exist for workspace '{workspace_id}'.")
216216
store_path = store_path if isinstance(store_path, Path) else Path(store_path)
217-
request = VisualExportRequest(dashboard_id=dashboard_id, file_name=file_name, metadata=metadata)
217+
if metadata is None:
218+
request = VisualExportRequest(dashboard_id=dashboard_id, file_name=file_name)
219+
else:
220+
request = VisualExportRequest(dashboard_id=dashboard_id, file_name=file_name, metadata=metadata)
218221
file_path = store_path / f"{file_name}.pdf"
219222
create_func = self._actions_api.create_pdf_export
220223
get_func = self._actions_api.get_exported_file

0 commit comments

Comments
 (0)