api: namespace create: lookup datastore with corret operation

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
Thomas Lamprecht 2022-05-16 18:26:55 +02:00
parent 6da6bafeac
commit ebab1e5ed9
1 changed files with 1 additions and 1 deletions

View File

@ -63,7 +63,7 @@ pub fn create_namespace(
proxmox_router::http_bail!(FORBIDDEN, "permission check failed"); proxmox_router::http_bail!(FORBIDDEN, "permission check failed");
} }
let datastore = DataStore::lookup_datastore(&store, Some(Operation::Read))?; let datastore = DataStore::lookup_datastore(&store, Some(Operation::Write))?;
datastore.create_namespace(&parent, name) datastore.create_namespace(&parent, name)
} }