Skip to content

Commit 635e0cc

Browse files
committed
CLN: clean up the function a bit
1 parent 870dc40 commit 635e0cc

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

pandas/_libs/tslibs/timestamps.pyx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1277,9 +1277,9 @@ def _fix_positional_arguments(cls):
12771277
# is now set to year and the other positional args
12781278
# are shifted to the left. Let's shift back
12791279
if len(args) > 2 and all(isinstance(arg, int) for arg in args[:3]):
1280-
args = (_no_input,) + args
1281-
instance = original_new(cls, *args, **kwargs)
1282-
return instance
1280+
return original_new(cls, _no_input, *args, **kwargs)
1281+
else:
1282+
return original_new(cls, *args, **kwargs)
12831283

12841284
cls.__new__ = updated_new
12851285
return cls

0 commit comments

Comments
 (0)