pub fn sync_in_background_yanked() {
    POOL.spawn(move || {
        let ns_started = crate::utils_mod::ns_start("sync_in_background_yanked");
        for x in unwrap!(crate::db_sled_mod::db_crate_mod::all_crates()).iter() {
            // println!("registry crate: {}", &x.crate_name);
            for (crate_version, yanked) in unwrap!(crate::cargo_registry_mod::info_for_one_crate(&x.crate_name)).iter() {
                let crate_name_version = join_crate_version(&x.crate_name, crate_version);
                if crate::db_sled_mod::db_yanked_mod::exists(&crate_name_version) && *yanked == false {
                    crate::db_sled_mod::db_yanked_mod::delete(&crate_name_version);
                } else if !crate::db_sled_mod::db_yanked_mod::exists(&crate_name_version) && *yanked == true {
                    unwrap!(crate::db_sled_mod::db_yanked_mod::insert(
                        &crate_name_version,
                        &YankedForDb {
                            crate_name_version: crate_name_version.clone(),
                        }
                    ));
                }
            }
        }
        crate::utils_mod::ns_print_ms("sync_in_background_yanked", ns_started);
    });
}
/// from cargo registry read all versions that are in db_version
/// only the yanked store in db_yanked
from cargo registry read all versions that are in db_version
only the yanked store in db_yanked
from cargo registry read all versions that are in db_version only the yanked store in db_yanked
pub fn sync_in_background_yanked() {
    POOL.spawn(move || {
        let ns_started = crate::utils_mod::ns_start("sync_in_background_yanked");
        for x in unwrap!(crate::db_sled_mod::db_crate_mod::all_crates()).iter() {
            // println!("registry crate: {}", &x.crate_name);
            for (crate_version, yanked) in unwrap!(crate::cargo_registry_mod::info_for_one_crate(&x.crate_name)).iter() {
                let crate_name_version = join_crate_version(&x.crate_name, crate_version);
                if crate::db_sled_mod::db_yanked_mod::exists(&crate_name_version) && *yanked == false {
                    crate::db_sled_mod::db_yanked_mod::delete(&crate_name_version);
                } else if !crate::db_sled_mod::db_yanked_mod::exists(&crate_name_version) && *yanked == true {
                    unwrap!(crate::db_sled_mod::db_yanked_mod::insert(
                        &crate_name_version,
                        &YankedForDb {
                            crate_name_version: crate_name_version.clone(),
                        }
                    ));
                }
            }
        }
        crate::utils_mod::ns_print_ms("sync_in_background_yanked", ns_started);
    });
}
pub fn sync_in_background_yanked ( ) { POOL . spawn ( move | | { let ns_started = crate :: utils_mod :: ns_start ( " " ) ; for x in unwrap ! ( crate db_sled_mod db_crate_mod all_crates ( ) ) . iter ( ) { // println!("registry crate: {}", &x.crate_name); for ( crate_version , yanked ) in unwrap ! ( crate cargo_registry_mod info_for_one_crate ( x crate_name ) ) . iter ( ) { let crate_name_version = join_crate_version ( & x . crate_name , crate_version ) ; if crate :: db_sled_mod :: db_yanked_mod :: exists ( & crate_name_version ) && * yanked == false { crate :: db_sled_mod :: db_yanked_mod :: delete ( & crate_name_version ) ; } else if ! crate :: db_sled_mod :: db_yanked_mod :: exists ( & crate_name_version ) && * yanked == true { unwrap ! ( crate db_sled_mod db_yanked_mod insert ( crate_name_version YankedForDb { crate_name_version crate_name_version clone ( ) } ) ) ; } } } crate :: utils_mod :: ns_print_ms ( " " , ns_started ) ; } ) ; }
from cargo registry read all versions that are in db_version
only the yanked store in db_yanked
from cargo registry read all versions that are in db_version only the yanked store in db_yanked