Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion pygmt/helpers/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -524,6 +524,8 @@ def build_arg_list( # noqa: PLR0912
['-A1/2/3/4', '-BWSen', '-Bxaf', '-Byaf', '-C1p', '-C2p']
>>> build_arg_list(dict(B=["af", "WSne+tBlank Space"]))
['-BWSne+tBlank Space', '-Baf']
>>> build_arg_list(dict(B=[True, "+tTitle"]))
['-B', '-B+tTitle']
>>> build_arg_list(dict(F='+t"Empty Spaces"'))
['-F+t"Empty Spaces"']
>>> build_arg_list(dict(l="'Void Space'"))
Expand Down Expand Up @@ -565,7 +567,10 @@ def build_arg_list( # noqa: PLR0912
elif value is True:
gmt_args.append(f"-{key}")
elif is_nonstr_iter(value):
gmt_args.extend(f"-{key}{_value}" for _value in value)
gmt_args.extend(
f"-{key}{_value}" if _value is not True else f"-{key}"
for _value in value
)
else:
gmt_args.append(f"-{key}{value}")

Expand Down
Loading