chrome 69 support

This commit is contained in:
Toshit Chawda 2024-09-07 11:42:11 -07:00
parent cc21e6c4a2
commit 07a304e9c6
No known key found for this signature in database
GPG key ID: 91480ED99E2B3D9D
4 changed files with 16 additions and 9 deletions

View file

@ -16,14 +16,14 @@ use hyper::{
body::Incoming,
upgrade::{self, Upgraded},
};
use js_sys::{ArrayBuffer, Function, Object, Uint8Array};
use js_sys::{ArrayBuffer, Function, Uint8Array};
use tokio::io::WriteHalf;
use wasm_bindgen::{prelude::*, JsError, JsValue};
use wasm_bindgen_futures::spawn_local;
use crate::{
tokioio::TokioIo,
utils::{entries_of_object, ws_key},
utils::{entries_of_object, from_entries, ws_key},
EpoxyClient, EpoxyError, EpoxyHandlers, HttpBody,
};
@ -69,7 +69,7 @@ impl EpoxyWebSocket {
}
if web_sys::Headers::instanceof(&headers)
&& let Ok(entries) = Object::from_entries(&headers)
&& let Ok(entries) = from_entries(&headers)
{
for header in entries_of_object(&entries) {
request = request.header(&header[0], &header[1]);