id: added id create for handling ID needs

This commit is contained in:
Philippe Loctaux 2023-03-05 23:27:34 +01:00
parent a5eafc49f5
commit 7851fdae1e
3 changed files with 84 additions and 0 deletions

12
crates/id/src/lib.rs Normal file
View file

@ -0,0 +1,12 @@
mod user;
// error
#[derive(thiserror::Error)]
// the rest
#[derive(Debug)]
pub enum Error {
#[error("Invalid {0} ID")]
Invalid(&'static str),
}
pub use user::UserID;