Skip to content
Snippets Groups Projects
Commit 3c28bdf0 authored by Éloïs's avatar Éloïs
Browse files

feat(identity): remove useless error `OwnerAccountNotExist` (!78)

* remove useless error `OwnerAccountNotExist`
parent ab5894ba
No related branches found
No related tags found
1 merge request!78feat(identity): remove useless error `OwnerAccountNotExist`
...@@ -247,11 +247,6 @@ pub mod pallet { ...@@ -247,11 +247,6 @@ pub mod pallet {
let creator_idty_val = let creator_idty_val =
Identities::<T>::try_get(&creator).map_err(|_| Error::<T>::IdtyNotFound)?; Identities::<T>::try_get(&creator).map_err(|_| Error::<T>::IdtyNotFound)?;
ensure!(
frame_system::Pallet::<T>::account_exists(&owner_key),
Error::<T>::OwnerAccountNotExist
);
if IdentityIndexOf::<T>::contains_key(&owner_key) { if IdentityIndexOf::<T>::contains_key(&owner_key) {
return Err(Error::<T>::IdtyAlreadyCreated.into()); return Err(Error::<T>::IdtyAlreadyCreated.into());
} }
...@@ -502,8 +497,9 @@ pub mod pallet { ...@@ -502,8 +497,9 @@ pub mod pallet {
RightNotExist, RightNotExist,
/// Identity creation period is not respected /// Identity creation period is not respected
NotRespectIdtyCreationPeriod, NotRespectIdtyCreationPeriod,
/// Owner account does not exist // Removed error: OwnerAccountNotExist,
OwnerAccountNotExist, // Caution: if you add a new error, you should explicitly set the index
// to not reuse the same index as the removed error.
} }
// PUBLIC FUNCTIONS // // PUBLIC FUNCTIONS //
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment