Skip to content

Commit ac99909

Browse files
committed
merge a message
1 parent 7df21c9 commit ac99909

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

shared-bindings/time/__init__.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -97,9 +97,7 @@ STATIC mp_obj_t struct_time_make_new(const mp_obj_type_t *type, size_t n_args, s
9797
size_t len;
9898
mp_obj_t *items;
9999
mp_obj_get_array(args[0], &len, &items);
100-
if (len != 9) {
101-
mp_raise_TypeError(translate("time.struct_time() takes a 9-sequence"));
102-
}
100+
mp_arg_validate_length(len, 9, MP_QSTR_value);
103101
return namedtuple_make_new(type, len, 0, items);
104102
}
105103

0 commit comments

Comments
 (0)