Skip to content

Commit

Permalink
fix(fc-traits-authn): implement a way to convert att to Dev
Browse files Browse the repository at this point in the history
  • Loading branch information
pandres95 committed Oct 11, 2024
1 parent 24a0a44 commit fef5850
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions traits/authn/src/util.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,12 @@ where
#[scale_info(skip_type_params(A, Ch, Cred))]
pub struct Dev<T, A, Ch, Cred>(T, PhantomData<(A, Ch, Cred)>);

impl<T, A, Ch, Cred> Dev<T, A, Ch, Cred> {
pub fn new(t: T) -> Self {
Self(t, PhantomData)
}
}

impl<T, A, Ch, Cred> UserAuthenticator for Dev<T, A, Ch, Cred>
where
T: AsRef<DeviceId> + FullCodec + MaxEncodedLen + TypeInfo + 'static,
Expand Down

0 comments on commit fef5850

Please sign in to comment.