settings: get first admin
This commit is contained in:
parent
0baeeadce9
commit
4bfc8a517f
4 changed files with 8 additions and 1 deletions
|
|
@ -20,6 +20,7 @@ impl From<DatabaseSettings> for Settings {
|
|||
.business_logo
|
||||
.unwrap_or_else(|| DEFAULT_BUSINESS_LOGO.to_vec()),
|
||||
url: db.url,
|
||||
first_admin: db.first_admin,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -14,6 +14,7 @@ pub struct Settings {
|
|||
business_name: String,
|
||||
business_logo: Vec<u8>,
|
||||
url: Option<String>,
|
||||
first_admin: Option<String>,
|
||||
}
|
||||
|
||||
impl Settings {
|
||||
|
|
@ -32,4 +33,7 @@ impl Settings {
|
|||
pub fn updated_at(&self) -> DateTime<Utc> {
|
||||
self.updated_at
|
||||
}
|
||||
pub fn first_admin(&self) -> Option<&str> {
|
||||
self.first_admin.as_deref()
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue