Fix compile checks on numerous packages using --all --all-features
This commit is contained in:
38 files changed
+147
-186
No files matched your search
@@ -21,7 +21,7 @@ use std::{
|
||||
use tokio::sync::broadcast::{self};
|
||||
|
||||
#[cfg(feature = "plugin")]
|
||||
use plugin::PluginManager;
|
||||
use crate::plugin::PluginManager;
|
||||
|
||||
use super::HotReloadState;
|
||||
|
||||
|
||||
@@ -110,7 +110,7 @@ async fn setup_file_watcher<F: Fn() -> Result<BuildResult> + Send + 'static>(
|
||||
);
|
||||
|
||||
#[cfg(feature = "plugin")]
|
||||
let _ = PluginManager::on_serve_rebuild(
|
||||
let _ = crate::plugin::PluginManager::on_serve_rebuild(
|
||||
chrono::Local::now().timestamp(),
|
||||
e.paths,
|
||||
);
|
||||
|
||||
@@ -39,7 +39,7 @@ use tower_http::{
|
||||
};
|
||||
|
||||
#[cfg(feature = "plugin")]
|
||||
use plugin::PluginManager;
|
||||
use crate::plugin::PluginManager;
|
||||
|
||||
mod proxy;
|
||||
|
||||
@@ -159,10 +159,10 @@ pub async fn serve(
|
||||
);
|
||||
|
||||
// Router
|
||||
let router = setup_router(config, ws_reload_state, hot_reload_state).await?;
|
||||
let router = setup_router(config.clone(), ws_reload_state, hot_reload_state).await?;
|
||||
|
||||
// Start server
|
||||
start_server(port, router, start_browser, rustls_config).await?;
|
||||
start_server(port, router, start_browser, rustls_config, &config).await?;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
@@ -366,10 +366,11 @@ async fn start_server(
|
||||
router: Router,
|
||||
start_browser: bool,
|
||||
rustls: Option<RustlsConfig>,
|
||||
config: &CrateConfig,
|
||||
) -> Result<()> {
|
||||
// If plugins, call on_serve_start event
|
||||
#[cfg(feature = "plugin")]
|
||||
PluginManager::on_serve_start(&config)?;
|
||||
PluginManager::on_serve_start(config)?;
|
||||
|
||||
// Parse address
|
||||
let addr = format!("0.0.0.0:{}", port).parse().unwrap();
|
||||
|
||||
Reference in new issue
Block a user