misc: use iterator to load data when getting used files (#55200)
This commit is contained in:
parent
ecb499305d
commit
0c3549872f
|
@ -1754,7 +1754,7 @@ def clean_unused_files(publisher):
|
|||
for option_data in (formdef.workflow_options or {}).values():
|
||||
if is_upload(option_data):
|
||||
yield option_data.get_fs_filename()
|
||||
for formdata in formdef.data_class().select(ignore_errors=True):
|
||||
for formdata in formdef.data_class().select(ignore_errors=True, iterator=True):
|
||||
for field_data in itertools.chain(
|
||||
(formdata.data or {}).values(), (formdata.workflow_data or {}).values()
|
||||
):
|
||||
|
|
Loading…
Reference in New Issue