src/config/*: add #[serde(skip_serializing_if="Option::is_none")] to optinal comment
This commit is contained in:
parent
454c13edce
commit
8aea35fcff
|
@ -31,6 +31,7 @@ pub const DIR_NAME_SCHEMA: Schema = StringSchema::new("Directory name").schema()
|
||||||
#[derive(Serialize,Deserialize)]
|
#[derive(Serialize,Deserialize)]
|
||||||
/// Datastore configuration properties.
|
/// Datastore configuration properties.
|
||||||
pub struct DataStoreConfig {
|
pub struct DataStoreConfig {
|
||||||
|
#[serde(skip_serializing_if="Option::is_none")]
|
||||||
pub comment: Option<String>,
|
pub comment: Option<String>,
|
||||||
pub path: String,
|
pub path: String,
|
||||||
}
|
}
|
||||||
|
|
|
@ -40,6 +40,7 @@ pub const REMOTE_PASSWORD_SCHEMA: Schema = StringSchema::new("Password or auth t
|
||||||
#[derive(Serialize,Deserialize)]
|
#[derive(Serialize,Deserialize)]
|
||||||
/// Remote properties.
|
/// Remote properties.
|
||||||
pub struct Remote {
|
pub struct Remote {
|
||||||
|
#[serde(skip_serializing_if="Option::is_none")]
|
||||||
pub comment: Option<String>,
|
pub comment: Option<String>,
|
||||||
pub host: String,
|
pub host: String,
|
||||||
pub userid: String,
|
pub userid: String,
|
||||||
|
|
Loading…
Reference in New Issue