api: add some missing sorted macro calls
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
This commit is contained in:
@ -2,6 +2,7 @@
|
||||
|
||||
use proxmox_router::list_subdirs_api_method;
|
||||
use proxmox_router::{Router, SubdirMap};
|
||||
use proxmox_sys::sortable;
|
||||
|
||||
pub mod access;
|
||||
pub mod acme;
|
||||
@ -16,7 +17,8 @@ pub mod tape_encryption_keys;
|
||||
pub mod traffic_control;
|
||||
pub mod verify;
|
||||
|
||||
const SUBDIRS: SubdirMap = &[
|
||||
#[sortable]
|
||||
const SUBDIRS: SubdirMap = &sorted!([
|
||||
("access", &access::ROUTER),
|
||||
("acme", &acme::ROUTER),
|
||||
("changer", &changer::ROUTER),
|
||||
@ -29,7 +31,7 @@ const SUBDIRS: SubdirMap = &[
|
||||
("tape-encryption-keys", &tape_encryption_keys::ROUTER),
|
||||
("traffic-control", &traffic_control::ROUTER),
|
||||
("verify", &verify::ROUTER),
|
||||
];
|
||||
]);
|
||||
|
||||
pub const ROUTER: Router = Router::new()
|
||||
.get(&list_subdirs_api_method!(SUBDIRS))
|
||||
|
@ -503,13 +503,13 @@ pub async fn scan_remote_groups(
|
||||
}
|
||||
|
||||
#[sortable]
|
||||
const DATASTORE_SCAN_SUBDIRS: SubdirMap = &[
|
||||
const DATASTORE_SCAN_SUBDIRS: SubdirMap = &sorted!([
|
||||
("groups", &Router::new().get(&API_METHOD_SCAN_REMOTE_GROUPS)),
|
||||
(
|
||||
"namespaces",
|
||||
&Router::new().get(&API_METHOD_SCAN_REMOTE_NAMESPACES),
|
||||
),
|
||||
];
|
||||
]);
|
||||
|
||||
const DATASTORE_SCAN_ROUTER: Router = Router::new()
|
||||
.get(&list_subdirs_api_method!(DATASTORE_SCAN_SUBDIRS))
|
||||
|
Reference in New Issue
Block a user