Skip to content

Commit 5b40a2e

Browse files
committed
Revert "Update packages/reflex-base/src/reflex_base/utils/lazy_loader.py"
This reverts commit eea00a4.
1 parent eea00a4 commit 5b40a2e

1 file changed

Lines changed: 2 additions & 7 deletions

File tree

packages/reflex-base/src/reflex_base/utils/lazy_loader.py

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -113,12 +113,6 @@ def comp_name(comp: str | tuple[str, str]) -> str:
113113
return comp[0] if isinstance(comp, tuple) else comp
114114

115115

116-
def comp_alias(comp: str | tuple[str, str]) -> str:
117-
"""Get the component alias from the mapping value.
118-
119-
This is the name external users will import.
120-
121-
Args:
122116
def comp_alias(comp: str | tuple[str, str]) -> str:
123117
"""Get the component alias from the mapping value.
124118
@@ -128,8 +122,9 @@ def comp_alias(comp: str | tuple[str, str]) -> str:
128122
comp: The component name or a tuple of (component name, alias).
129123
130124
Returns:
131-
The component alias, or the component name itself if there is no alias.
125+
The component alias, or None if there is no alias.
132126
"""
127+
return comp[1] if isinstance(comp, tuple) else comp
133128

134129

135130
def comp_path(path: str, comp: str | tuple[str, str]) -> str:

0 commit comments

Comments
 (0)