Don't calculate real path in tool action code if unused.

This commit is contained in:
John Chilton
2019-05-27 14:37:53 +02:00
committed by mvdbeek
parent 7ea502be77
commit 419bae1f09
+1 -1
View File
@@ -322,7 +322,7 @@ class HasDatasets(object):
def _dataset_wrapper(self, dataset, dataset_paths, **kwargs):
wrapper_kwds = kwargs.copy()
if dataset:
if dataset and dataset_paths:
real_path = dataset.file_name
if real_path in dataset_paths:
wrapper_kwds["dataset_path"] = dataset_paths[real_path]