Skip to content

Commit

Permalink
Remove one time code to unsuspend a few users (#5262)
Browse files Browse the repository at this point in the history
  • Loading branch information
hpeebles authored Jan 25, 2024
1 parent 266794f commit 7c96ab3
Showing 1 changed file with 0 additions and 22 deletions.
22 changes: 0 additions & 22 deletions backend/canisters/user_index/impl/src/lifecycle/post_upgrade.rs
Original file line number Diff line number Diff line change
@@ -1,15 +1,11 @@
use crate::lifecycle::{init_env, init_state};
use crate::memory::get_upgrades_memory;
use crate::updates::unsuspend_user::unsuspend_user_impl;
use crate::Data;
use candid::Principal;
use canister_logger::LogEntry;
use canister_tracing_macros::trace;
use ic_cdk_macros::post_upgrade;
use stable_memory::get_reader;
use std::time::Duration;
use tracing::info;
use types::UserId;
use user_index_canister::post_upgrade::Args;
use utils::cycles::init_cycles_dispenser_client;

Expand All @@ -28,22 +24,4 @@ fn post_upgrade(args: Args) {
init_state(env, data, args.wasm_version);

info!(version = %args.wasm_version, "Post-upgrade complete");

let users_to_unsuspend: Vec<UserId> = [
"qyzts-uiaaa-aaaar-aw4ca-cai",
"zjayq-ryaaa-aaaar-axhrq-cai",
"o6334-oyaaa-aaaar-awgxa-cai",
"s4i57-nqaaa-aaaar-abzcq-cai",
"vecg6-eqaaa-aaaar-a23rq-cai",
"ne6gg-dqaaa-aaaaf-agzwa-cai",
]
.iter()
.map(|str| Principal::from_text(str).unwrap().into())
.collect();

ic_cdk_timers::set_timer(Duration::ZERO, || {
ic_cdk::spawn(async move {
futures::future::join_all(users_to_unsuspend.into_iter().map(unsuspend_user_impl)).await;
})
});
}

0 comments on commit 7c96ab3

Please sign in to comment.