update api macro invocation to new style
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
This commit is contained in:
parent
314bb35868
commit
7b6c41078b
|
@ -36,8 +36,8 @@ fn authenticate_user(username: &str, password: &str) -> Result<(), Error> {
|
||||||
bail!("inavlid credentials");
|
bail!("inavlid credentials");
|
||||||
}
|
}
|
||||||
|
|
||||||
#[api]
|
#[api(
|
||||||
#[input({
|
input: {
|
||||||
properties: {
|
properties: {
|
||||||
username: {
|
username: {
|
||||||
type: String,
|
type: String,
|
||||||
|
@ -49,8 +49,8 @@ fn authenticate_user(username: &str, password: &str) -> Result<(), Error> {
|
||||||
description: "The secret password. This can also be a valid ticket.",
|
description: "The secret password. This can also be a valid ticket.",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
})]
|
},
|
||||||
#[returns({
|
returns: {
|
||||||
properties: {
|
properties: {
|
||||||
username: {
|
username: {
|
||||||
type: String,
|
type: String,
|
||||||
|
@ -65,8 +65,9 @@ fn authenticate_user(username: &str, password: &str) -> Result<(), Error> {
|
||||||
description: "Cross Site Request Forgery Prevention Token.",
|
description: "Cross Site Request Forgery Prevention Token.",
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
})]
|
},
|
||||||
#[protected]
|
protected: true,
|
||||||
|
)]
|
||||||
/// Create or verify authentication ticket.
|
/// Create or verify authentication ticket.
|
||||||
///
|
///
|
||||||
/// Returns: An authentication ticket with additional infos.
|
/// Returns: An authentication ticket with additional infos.
|
||||||
|
|
Loading…
Reference in New Issue