Skip to content

Commit d032a6e

Browse files
committed
correct last commit
1 parent 33aa7e5 commit d032a6e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pandas/core/arrays/integer.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
is_object_dtype,
2121
is_scalar,
2222
)
23-
from pandas.core.dtypes.dtypes import register_extension_dtype
23+
from pandas.core.dtypes.dtypes import register_extension_dtype, CategoricalDtype
2424
from pandas.core.dtypes.missing import isna, notna
2525

2626
from pandas.core import nanops, ops
@@ -208,7 +208,7 @@ def coerce_to_array(values, dtype, mask=None, copy=False):
208208

209209

210210
if hasattr(values, "dtype"):
211-
if copy and values.dtype!="category":
211+
if copy and values.dtype!=CategoricalDtype():
212212
values = values.copy()
213213
else:
214214
if isinstance(values, list):

0 commit comments

Comments
 (0)