Fix a reportUnnecessaryIsInstance Pyright warning (#4263)
This commit is contained in:
parent
d781c9d857
commit
d413c01fde
|
|
@ -317,10 +317,6 @@ class Size:
|
||||||
unit: Unit
|
unit: Unit
|
||||||
sector_size: SectorSize
|
sector_size: SectorSize
|
||||||
|
|
||||||
def __post_init__(self) -> None:
|
|
||||||
if not isinstance(self.sector_size, SectorSize):
|
|
||||||
raise ValueError('sector size must be of type SectorSize')
|
|
||||||
|
|
||||||
def json(self) -> _SizeSerialization:
|
def json(self) -> _SizeSerialization:
|
||||||
return {
|
return {
|
||||||
'value': self.value,
|
'value': self.value,
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue