This commit is contained in:
Nicolas Lepage 2021-01-28 11:05:59 +01:00
parent b3e8d72ed1
commit 472360783b
No known key found for this signature in database
GPG Key ID: B0879E35E66D8F6F
2 changed files with 4 additions and 4 deletions

View File

@ -11,9 +11,9 @@
</a> </a>
</p> </p>
> WebAssembly Go HTTP Server embedded in a ServiceWorker > Build your Go HTTP Server to [WebAssembly](https://mdn.io/WebAssembly/) and embed it in a ServiceWorker!
### ✨ [Demo](https://nlepage.github.io/go-wasm-http-server/) ✨ [Demos](https://nlepage.github.io/go-wasm-http-server/)
## Install ## Install
@ -35,7 +35,7 @@ TODO
👤 **Nicolas Lepage** 👤 **Nicolas Lepage**
* Website: https://nicolas.lepage.dev * Website: https://nicolas.lepage.dev/
* Twitter: [@njblepage](https://twitter.com/njblepage) * Twitter: [@njblepage](https://twitter.com/njblepage)
* Github: [@nlepage](https://github.com/nlepage) * Github: [@nlepage](https://github.com/nlepage)

View File

@ -32,7 +32,7 @@ func (rr ResponseRecorder) JSValue() js.Value {
js.CopyBytesToJS(body, b) js.CopyBytesToJS(body, b)
} }
var init = make(map[string]interface{}) var init = make(map[string]interface{}, 2)
if res.StatusCode != 0 { if res.StatusCode != 0 {
init["status"] = res.StatusCode init["status"] = res.StatusCode