Can you use `HttpRequest.postFormData()` to simplify this code? I think that's the dart-y API and it looks like you're using the javascriptish api.