Make set aware of Attribute categories
This commit is contained in:
parent
5b85ec128e
commit
72ad633071
5 changed files with 182 additions and 97 deletions
|
|
@ -395,12 +395,13 @@ def iter_to_str(iterable, endsep=", and", addquote=False):
|
|||
"""
|
||||
if not iterable:
|
||||
return ""
|
||||
iterable = list(make_iter(iterable))
|
||||
len_iter = len(iterable)
|
||||
|
||||
if addquote:
|
||||
iterable = tuple(f'"{val}"' for val in make_iter(iterable))
|
||||
iterable = tuple(f'"{val}"' for val in iterable)
|
||||
else:
|
||||
iterable = tuple(str(val) for val in make_iter(iterable))
|
||||
iterable = tuple(str(val) for val in iterable)
|
||||
|
||||
if endsep.startswith(","):
|
||||
# oxford comma alternative
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue