remove length check of fixed size

This commit is contained in:
sjorsdonkers
2025-09-05 16:43:28 +02:00
committed by Muki Kiboigo
parent 8295c2abe5
commit a5e2e8ea15

View File

@@ -74,11 +74,6 @@ pub fn constructor(_init: ?HeadersInit, page: *Page) !Headers {
switch (init) {
.strings => |kvs| {
for (kvs) |pair| {
// Can only have two string elements if in a pair.
if (pair.len != 2) {
return error.TypeError;
}
const key = try arena.dupe(u8, pair[0]);
const value = try arena.dupe(u8, pair[1]);