Signed-off-by: -LAN- <laipz8200@outlook.com> Co-authored-by: lix43 <lix43@chinatelecom.cn> Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com> Co-authored-by: -LAN- <laipz8200@outlook.com>
This commit is contained in:
parent
fd86cadf67
commit
6462328620
3 changed files with 130 additions and 4 deletions
|
|
@ -142,6 +142,8 @@ def build_segment(value: Any, /) -> Segment:
|
|||
# below
|
||||
if value is None:
|
||||
return NoneSegment()
|
||||
if isinstance(value, Segment):
|
||||
return value
|
||||
if isinstance(value, str):
|
||||
return StringSegment(value=value)
|
||||
if isinstance(value, bool):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue