const VALUE_UNKNOWN: &str = "-";
#[cached(size = 1, time = 10)]
-fn get_valheim_executable_information_cached(world_path: String) -> Option<valheim_controller::ValheimExe> {
- valheim_controller::get_valheim_executable_information(&world_path)
+fn get_valheim_executable_information_cached(world_path: String, backup_path: String) -> Option<valheim_controller::ValheimExe> {
+ valheim_controller::get_valheim_executable_information(&world_path, &backup_path)
}
#[get("/")]
async fn main_page(config_shared: web::Data<Mutex<Config>>) -> impl Responder {
let config = config_shared.lock().unwrap();
- match get_valheim_executable_information_cached(config.world_path.clone()) {
+ match get_valheim_executable_information_cached(config.world_path.clone(), config.backup_path.clone()) {
Some(info) =>
MainTemplate {
text_status: String::from("Valheim server is up and running :)"),