storage: support resumable uploads

## Do not merge!

RE: #298

It works!

It's 200 lines, but it works!

(Still needs tests, but regressions work as usual)
Ooops, okay that should work. Just weird that you're using a type check rather than just something like === null