mirror of
				https://gitlab.com/comunic/comunicapiv3
				synced 2025-11-04 09:34:04 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			18 lines
		
	
	
		
			332 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
			
		
		
	
	
			18 lines
		
	
	
		
			332 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
use serde::{Deserialize, Serialize};
 | 
						|
 | 
						|
use crate::data::user::UserID;
 | 
						|
 | 
						|
/// Current user ID
 | 
						|
#[derive(Serialize, Deserialize)]
 | 
						|
#[allow(non_snake_case)]
 | 
						|
pub struct CurrentUserID {
 | 
						|
    userID: u64
 | 
						|
}
 | 
						|
 | 
						|
impl CurrentUserID {
 | 
						|
    pub fn new(id: &UserID) -> CurrentUserID {
 | 
						|
        CurrentUserID {
 | 
						|
            userID: id.id()
 | 
						|
        }
 | 
						|
    }
 | 
						|
} |