Skip to content
Snippets Groups Projects
Commit 159e7d50 authored by Yuanchao Sun's avatar Yuanchao Sun Committed by GitHub
Browse files

Expose key_owner(), so other pallets can look up validator ID by the (#8506)

session key.
parent 484a630d
No related merge requests found
......@@ -819,7 +819,8 @@ impl<T: Config> Module<T> {
<NextKeys<T>>::insert(v, keys);
}
fn key_owner(id: KeyTypeId, key_data: &[u8]) -> Option<T::ValidatorId> {
/// Query the owner of a session key by returning the owner's validator ID.
pub fn key_owner(id: KeyTypeId, key_data: &[u8]) -> Option<T::ValidatorId> {
<KeyOwner<T>>::get((id, key_data))
}
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment