Rewrote multipart/* algorithm to be recursive