kpcli fix stage 1
This commit is contained in:
@@ -1,8 +1,6 @@
|
|||||||
mod client;
|
mod client;
|
||||||
mod db;
|
mod db;
|
||||||
mod printers;
|
mod printers;
|
||||||
|
|
||||||
#[cfg(target_os = "linux")]
|
|
||||||
mod daemon;
|
mod daemon;
|
||||||
|
|
||||||
use anyhow::Result;
|
use anyhow::Result;
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
use dbus::arg::{self, RefArg};
|
|
||||||
use kordophone::model::message::AttachmentMetadata;
|
use kordophone::model::message::AttachmentMetadata;
|
||||||
use pretty::RcDoc;
|
use pretty::RcDoc;
|
||||||
use std::collections::HashMap;
|
use std::collections::HashMap;
|
||||||
@@ -44,8 +43,9 @@ impl From<kordophone_db::models::Conversation> for PrintableConversation {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl From<arg::PropMap> for PrintableConversation {
|
#[cfg(target_os = "linux")]
|
||||||
fn from(value: arg::PropMap) -> Self {
|
impl From<dbus::arg::PropMap> for PrintableConversation {
|
||||||
|
fn from(value: dbus::arg::PropMap) -> Self {
|
||||||
Self {
|
Self {
|
||||||
guid: value.get("guid").unwrap().as_str().unwrap().to_string(),
|
guid: value.get("guid").unwrap().as_str().unwrap().to_string(),
|
||||||
date: OffsetDateTime::from_unix_timestamp(value.get("date").unwrap().as_i64().unwrap())
|
date: OffsetDateTime::from_unix_timestamp(value.get("date").unwrap().as_i64().unwrap())
|
||||||
@@ -114,8 +114,9 @@ impl From<kordophone_db::models::Message> for PrintableMessage {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl From<arg::PropMap> for PrintableMessage {
|
#[cfg(target_os = "linux")]
|
||||||
fn from(value: arg::PropMap) -> Self {
|
impl From<dbus::arg::PropMap> for PrintableMessage {
|
||||||
|
fn from(value: dbus::arg::PropMap) -> Self {
|
||||||
// Parse file transfer GUIDs from JSON if present
|
// Parse file transfer GUIDs from JSON if present
|
||||||
let file_transfer_guids = value
|
let file_transfer_guids = value
|
||||||
.get("file_transfer_guids")
|
.get("file_transfer_guids")
|
||||||
|
|||||||
Reference in New Issue
Block a user