Skip to content

Commit 29542b2

Browse files
committed
removed extra if statement
1 parent d3ed71e commit 29542b2

File tree

1 file changed

+0
-5
lines changed

1 file changed

+0
-5
lines changed

pandas/core/dtypes/dtypes.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2277,11 +2277,6 @@ def name(self) -> str: # type: ignore[override]
22772277
@cache_readonly
22782278
def numpy_dtype(self) -> np.dtype:
22792279
"""Return an instance of the related numpy dtype"""
2280-
if pa.types.is_string(self.pyarrow_dtype) or pa.types.is_large_string(
2281-
self.pyarrow_dtype
2282-
):
2283-
# pa.string().to_pandas_dtype() = object which we don't want
2284-
return np.dtype(str)
22852280
try:
22862281
return np.dtype(self.pyarrow_dtype.to_pandas_dtype())
22872282
except (NotImplementedError, TypeError):

0 commit comments

Comments
 (0)