mirror of
https://gitlab.com/comunic/comunicapiv3
synced 2025-06-21 00:45:18 +00:00
Can check if security questions has been defined
This commit is contained in:
@ -43,4 +43,5 @@ pub mod res_count_all_unreads;
|
||||
pub mod notification_api;
|
||||
pub mod user_membership_api;
|
||||
mod type_container_api;
|
||||
pub mod res_check_email_exists;
|
||||
pub mod res_check_email_exists;
|
||||
pub mod res_check_security_questions_exists;
|
@ -4,7 +4,6 @@
|
||||
use serde::Serialize;
|
||||
|
||||
#[derive(Serialize)]
|
||||
#[allow(non_snake_case)]
|
||||
pub struct ResCheckEmailExists {
|
||||
exists: bool
|
||||
}
|
||||
|
15
src/api_data/res_check_security_questions_exists.rs
Normal file
15
src/api_data/res_check_security_questions_exists.rs
Normal file
@ -0,0 +1,15 @@
|
||||
//! # Check if security questions are set for a user
|
||||
//!
|
||||
//! @author Pierre Hubert
|
||||
use serde::Serialize;
|
||||
|
||||
#[derive(Serialize)]
|
||||
pub struct ResCheckSecurityQuestionsExists {
|
||||
defined: bool
|
||||
}
|
||||
|
||||
impl ResCheckSecurityQuestionsExists {
|
||||
pub fn new(defined: bool) -> ResCheckSecurityQuestionsExists {
|
||||
ResCheckSecurityQuestionsExists { defined }
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user