File tree Expand file tree Collapse file tree 2 files changed +3
-6
lines changed
Expand file tree Collapse file tree 2 files changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -190,8 +190,7 @@ def __init__(
190190
191191 Doesn't apply to the conventions ``"aki"``, ``"gcmt"``, and ``"partial"``.
192192 """
193- # TODO(Python>=3.12): Simplify to "convention in _FocalMechanismConventionCode".
194- if convention in _FocalMechanismConventionCode .__members__ .values ():
193+ if convention in _FocalMechanismConventionCode :
195194 # Convention is specified via the actual single-letter convention code.
196195 self .code = _FocalMechanismConventionCode (convention )
197196 # Parse the convention from the convention code name.
Original file line number Diff line number Diff line change @@ -209,8 +209,7 @@ def registration(self) -> GridRegistration:
209209
210210 @registration .setter
211211 def registration (self , value : GridRegistration | int ):
212- # TODO(Python>=3.12): Simplify to `if value not in GridRegistration`.
213- if value not in GridRegistration .__members__ .values ():
212+ if value not in GridRegistration :
214213 raise GMTValueError (
215214 value , description = "grid registration" , choices = GridRegistration
216215 )
@@ -225,8 +224,7 @@ def gtype(self) -> GridType:
225224
226225 @gtype .setter
227226 def gtype (self , value : GridType | int ):
228- # TODO(Python>=3.12): Simplify to `if value not in GridType`.
229- if value not in GridType .__members__ .values ():
227+ if value not in GridType :
230228 raise GMTValueError (
231229 value , description = "grid coordinate system type" , choices = GridType
232230 )
You can’t perform that action at this time.
0 commit comments