fix build

This commit is contained in:
Aiden McClelland
2023-08-08 12:03:54 -06:00
parent 7becdc3034
commit 72ffedead7
3 changed files with 10 additions and 3 deletions

View File

@@ -13,6 +13,7 @@ use crate::{
config::hook::ConfigHook,
manager::{start_stop::StartStop, Manager},
net::keys::Key,
net::vhost::AlpnInfo,
};
use super::try_get_running_ip;
@@ -96,7 +97,13 @@ impl OsApi for Manager {
let mut tx = secrets.begin().await?;
let addr = svc
.add_lan(&mut tx, id.clone(), external_port, internal_port, false)
.add_lan(
&mut tx,
id.clone(),
external_port,
internal_port,
Err(AlpnInfo::Specified(vec![])),
)
.await
.map_err(|e| eyre!("Could not add to local: {e:?}"))?;

View File

@@ -310,7 +310,7 @@ impl NetService {
.await?,
);
self.lan.insert(lan_idx, lan);
Ok(addr)
Ok(())
}
pub async fn remove_lan(&mut self, id: InterfaceId, external: u16) -> Result<(), Error> {
let ctrl = self.net_controller()?;

View File

@@ -425,7 +425,7 @@ impl<'a> Future for RuntimeEventLoop<'a> {
if let Poll::Ready(Some((uuid, args))) = this.callback_receiver.poll_recv(cx) {
match this.runtime.execute_script(
"callback",
&format!("globalThis.runCallback(\"{uuid}\", {})", Value::Array(args)),
format!("globalThis.runCallback(\"{uuid}\", {})", Value::Array(args)).into(),
) {
Ok(_) => (),
Err(e) => return Poll::Ready(Err(e)),