various: bump dependencies; wire up dead code
Signed-off-by: NotAShelf <raf@notashelf.dev> Change-Id: I12432bc956453cc4b0a2db82dce1b4976a6a6964
This commit is contained in:
parent
4f878b5abe
commit
875bdf5ebc
6 changed files with 764 additions and 427 deletions
|
|
@ -482,34 +482,6 @@ impl ApiClient {
|
|||
.await?)
|
||||
}
|
||||
|
||||
pub async fn batch_import(
|
||||
&self,
|
||||
paths: &[String],
|
||||
tag_ids: &[String],
|
||||
new_tags: &[String],
|
||||
collection_id: Option<&str>,
|
||||
) -> Result<BatchImportResponse> {
|
||||
let mut body = serde_json::json!({"paths": paths});
|
||||
if !tag_ids.is_empty() {
|
||||
body["tag_ids"] = serde_json::json!(tag_ids);
|
||||
}
|
||||
if !new_tags.is_empty() {
|
||||
body["new_tags"] = serde_json::json!(new_tags);
|
||||
}
|
||||
if let Some(cid) = collection_id {
|
||||
body["collection_id"] = serde_json::json!(cid);
|
||||
}
|
||||
Ok(self
|
||||
.client
|
||||
.post(self.url("/media/import/batch"))
|
||||
.json(&body)
|
||||
.send()
|
||||
.await?
|
||||
.error_for_status()?
|
||||
.json()
|
||||
.await?)
|
||||
}
|
||||
|
||||
pub async fn import_directory(
|
||||
&self,
|
||||
path: &str,
|
||||
|
|
@ -967,17 +939,6 @@ impl ApiClient {
|
|||
|
||||
// ── UI Config ──
|
||||
|
||||
pub async fn get_ui_config(&self) -> Result<UiConfigResponse> {
|
||||
Ok(self
|
||||
.client
|
||||
.get(self.url("/config/ui"))
|
||||
.send()
|
||||
.await?
|
||||
.error_for_status()?
|
||||
.json()
|
||||
.await?)
|
||||
}
|
||||
|
||||
pub async fn update_ui_config(&self, updates: serde_json::Value) -> Result<UiConfigResponse> {
|
||||
Ok(self
|
||||
.client
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue