Some more changes

This commit is contained in:
Sky O 2024-03-29 19:13:21 +00:00
parent c3e99cb15d
commit fbd1fbf27f

View File

@ -32,40 +32,32 @@ def get_body_from_form_data(
def on_part_data(b,s,e):
current_part.data = b[s:e]
print("YO PART DATA", b[s:e])
return
def on_part_end():
parts.append(current_part)
print("YO PART ENDED")
return
def on_header_begin():
print("YO HEADER BEGIN")
h = Header()
current_part.headers.append(h)
return
def on_header_end():
print("YO HEADER END")
return
def on_header_field(b,s,e):
h = Header()
h.name = b[s:e]
current_part.headers.append(h)
print("YO HEADER FIELD", )
current_part.headers[-1].name = b[s:e]
return
def on_header_value(b,s,e):
current_part.headers[-1].value = b[s:e]
print("YO HEADER VALUE", b[s:e])
return
def on_headers_finished():
print("YO HEADER FINISHED")
return
def on_end():
print("YO END")
return
parser = multipart.MultipartParser(