From 4849a7b67f4f4fd67c81c31e3023dc18511a8b81 Mon Sep 17 00:00:00 2001 From: Hugo Trentesaux <hugo@trentesaux.fr> Date: Tue, 16 May 2023 23:17:39 +0200 Subject: [PATCH] remove origin from force_add_cert --- pallets/duniter-wot/src/lib.rs | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/pallets/duniter-wot/src/lib.rs b/pallets/duniter-wot/src/lib.rs index b672b30f7..adc21d573 100644 --- a/pallets/duniter-wot/src/lib.rs +++ b/pallets/duniter-wot/src/lib.rs @@ -303,12 +303,9 @@ impl<T: Config<I>, I: 'static> pallet_identity::traits::OnIdtyChange<T> for Pall fn on_idty_change(idty_index: IdtyIndex, idty_event: &IdtyEvent<T>) -> Weight { match idty_event { IdtyEvent::Created { creator } => { - if let Err(e) = <pallet_certification::Pallet<T, I>>::force_add_cert( - frame_system::Origin::<T>::Root.into(), - *creator, - idty_index, - true, - ) { + if let Err(e) = + <pallet_certification::Pallet<T, I>>::force_add_cert(*creator, idty_index, true) + { sp_std::if_std! { println!("fail to force add cert: {:?}", e) } -- GitLab