Application Crypto cleanup (#13746)

* Adjust application crypto docs

* Blanket implementation for 'RuntimeAppPublic' trait

* Blanket implementation for 'BoundToRuntimeAppPublic' for 'RuntimeAppPublic'

* Relax type bounds

* Docs fix

* restore MaybeHash

* Commit suggestion

Co-authored-by: Anton <anton.kalyaev@gmail.com>

---------

Co-authored-by: Anton <anton.kalyaev@gmail.com>
This commit is contained in:
Davide Galassi
2023-03-30 10:30:35 +02:00
committed by GitHub
parent 29e31f2b0a
commit 7985495b8c
7 changed files with 91 additions and 111 deletions
+1 -6
View File
@@ -26,7 +26,7 @@ use crate::{
PostDispatchInfoOf, SignedExtension, ValidateUnsigned,
},
transaction_validity::{TransactionSource, TransactionValidity, TransactionValidityError},
ApplyExtrinsicResultWithInfo, CryptoTypeId, KeyTypeId,
ApplyExtrinsicResultWithInfo, KeyTypeId,
};
use serde::{de::Error as DeError, Deserialize, Deserializer, Serialize, Serializer};
use sp_core::{
@@ -115,7 +115,6 @@ impl UintAuthorityId {
impl sp_application_crypto::RuntimeAppPublic for UintAuthorityId {
const ID: KeyTypeId = key_types::DUMMY;
const CRYPTO_ID: CryptoTypeId = CryptoTypeId(*b"dumm");
type Signature = TestSignature;
@@ -157,10 +156,6 @@ impl OpaqueKeys for UintAuthorityId {
}
}
impl crate::BoundToRuntimeAppPublic for UintAuthorityId {
type Public = Self;
}
impl traits::IdentifyAccount for UintAuthorityId {
type AccountId = u64;