From: Stoiko Ivanov <s.ivanov@proxmox.com>
To: pbs-devel@lists.proxmox.com
Subject: [pbs-devel] [PATCH proxmox-backup 1/6] api: config: acme: rustfmt
Date: Tue, 9 Nov 2021 16:54:17 +0000 [thread overview]
Message-ID: <20211109165422.311089-4-s.ivanov@proxmox.com> (raw)
In-Reply-To: <20211109165422.311089-1-s.ivanov@proxmox.com>
Signed-off-by: Stoiko Ivanov <s.ivanov@proxmox.com>
---
src/api2/config/acme.rs | 32 ++++++++++++++++++++++----------
1 file changed, 22 insertions(+), 10 deletions(-)
diff --git a/src/api2/config/acme.rs b/src/api2/config/acme.rs
index c24c7850..7ed55a75 100644
--- a/src/api2/config/acme.rs
+++ b/src/api2/config/acme.rs
@@ -10,7 +10,7 @@ use serde::{Deserialize, Serialize};
use serde_json::{json, Value};
use proxmox_router::{
- http_bail, list_subdirs_api_method, Permission, Router, SubdirMap, RpcEnvironment,
+ http_bail, list_subdirs_api_method, Permission, Router, RpcEnvironment, SubdirMap,
};
use proxmox_schema::api;
@@ -336,7 +336,8 @@ pub fn deactivate_account(
task_warn!(
worker,
"error deactivating account {}, proceedeing anyway - {}",
- name, err,
+ name,
+ err,
);
}
}
@@ -630,7 +631,7 @@ pub fn delete_plugin(id: String) -> Result<(), Error> {
#[api()]
#[derive(Serialize, Deserialize)]
-#[serde(rename_all="kebab-case")]
+#[serde(rename_all = "kebab-case")]
#[allow(non_camel_case_types)]
/// Deletable property name
pub enum DeletableProperty {
@@ -709,16 +710,27 @@ pub fn update_plugin(
if let Some(delete) = delete {
for delete_prop in delete {
match delete_prop {
- DeletableProperty::validation_delay => { plugin.core.validation_delay = None; },
- DeletableProperty::disable => { plugin.core.disable = None; },
+ DeletableProperty::validation_delay => {
+ plugin.core.validation_delay = None;
+ }
+ DeletableProperty::disable => {
+ plugin.core.disable = None;
+ }
}
}
}
- if let Some(data) = data { plugin.data = data; }
- if let Some(api) = update.api { plugin.core.api = api; }
- if update.validation_delay.is_some() { plugin.core.validation_delay = update.validation_delay; }
- if update.disable.is_some() { plugin.core.disable = update.disable; }
-
+ if let Some(data) = data {
+ plugin.data = data;
+ }
+ if let Some(api) = update.api {
+ plugin.core.api = api;
+ }
+ if update.validation_delay.is_some() {
+ plugin.core.validation_delay = update.validation_delay;
+ }
+ if update.disable.is_some() {
+ plugin.core.disable = update.disable;
+ }
*entry = serde_json::to_value(plugin)?;
}
--
2.30.2
next prev parent reply other threads:[~2021-11-09 16:59 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-11-09 16:54 [pbs-devel] [PATCH proxmox-backup/proxmox-acme-rs/pwt] acme: add support for http_proxy and wildcard certs Stoiko Ivanov
2021-11-09 16:54 ` [pbs-devel] [PATCH widget-toolkit 1/1] acmeplugin: add use-proxy checkbox Stoiko Ivanov
2021-11-09 16:54 ` [pbs-devel] [PATCH proxmox-acme-rs 1/1] client: add support for proxies Stoiko Ivanov
2021-11-18 10:15 ` [pbs-devel] applied: " Wolfgang Bumiller
2021-11-09 16:54 ` Stoiko Ivanov [this message]
2021-11-18 10:33 ` [pbs-devel] applied: [PATCH proxmox-backup 1/6] api: config: acme: rustfmt Wolfgang Bumiller
2021-11-09 16:54 ` [pbs-devel] [PATCH proxmox-backup 2/6] config: acme: plugin: rustfmt Stoiko Ivanov
2021-11-18 10:34 ` [pbs-devel] applied: " Wolfgang Bumiller
2021-11-09 16:54 ` [pbs-devel] [PATCH proxmox-backup 3/6] api: acme: fix typo Stoiko Ivanov
2021-11-18 10:34 ` [pbs-devel] applied: " Wolfgang Bumiller
2021-11-09 16:54 ` [pbs-devel] [PATCH proxmox-backup 4/6] acme: client: read http_proxy from node config Stoiko Ivanov
2021-11-09 16:54 ` [pbs-devel] [PATCH proxmox-backup 5/6] acme: plugin: add 'use-proxy' property Stoiko Ivanov
2021-11-09 16:54 ` [pbs-devel] [PATCH proxmox-backup 6/6] acme: add support for wildcard certificates Stoiko Ivanov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20211109165422.311089-4-s.ivanov@proxmox.com \
--to=s.ivanov@proxmox.com \
--cc=pbs-devel@lists.proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox