Skip to content

Commit fae3ab0

Browse files
committed
Put name after value
1 parent bc0401e commit fae3ab0

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

pygmt/alias.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -143,6 +143,8 @@ class Alias:
143143
----------
144144
value
145145
The value of the alias.
146+
name
147+
The name of the parameter to be used in the error message.
146148
prefix
147149
The string to add as a prefix to the returned value.
148150
mapping
@@ -155,8 +157,6 @@ class Alias:
155157
sequence, it is the allowed size of the 1-D sequence.
156158
ndim
157159
The expected maximum number of dimensions of the sequence.
158-
name
159-
The name of the parameter to be used in the error message.
160160
161161
Examples
162162
--------
@@ -174,12 +174,12 @@ class Alias:
174174
"""
175175

176176
value: Any
177+
name: str | None = None
177178
prefix: str = ""
178179
mapping: Mapping | None = None
179180
separator: Literal["/", ","] | None = None
180181
size: int | Sequence[int] | None = None
181182
ndim: int = 1
182-
name: str | None = None
183183

184184
@property
185185
def _value(self) -> str | list[str] | None:
@@ -188,10 +188,10 @@ def _value(self) -> str | list[str] | None:
188188
"""
189189
return _to_string(
190190
value=self.value,
191+
name=self.name,
191192
prefix=self.prefix,
192193
mapping=self.mapping,
193194
separator=self.separator,
194195
size=self.size,
195196
ndim=self.ndim,
196-
name=self.name,
197197
)

0 commit comments

Comments
 (0)