Update reflex/compiler/utils.py

Co-authored-by: Masen Furer <m_github@0x26.net>
This commit is contained in:
Thomas Brandého 2024-12-10 19:42:47 +01:00 committed by GitHub
parent f2da5e88eb
commit dfe3a0a1ec
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -123,7 +123,7 @@ def compile_imports(import_dict: ParsedImportDict) -> list[dict]:
raise ValueError("No default field allowed for empty library.")
if rest is None or len(rest) == 0:
raise ValueError("No fields to import.")
import_dicts.extend([get_import_dict(module) for module in sorted(rest)])
import_dicts.extend(get_import_dict(module) for module in sorted(rest))
continue
# remove the version before rendering the package imports