Minor cleanup of Viewtype

Provide checking for attachment as a method and move it to the message
module.  The method is a lot easier to read and have correct
expectations about.
This commit is contained in:
Floris Bruynooghe
2022-03-06 17:54:23 +01:00
parent 50f13cb84b
commit f9ee70aa2e
28 changed files with 204 additions and 201 deletions

View File

@@ -12,7 +12,7 @@ use once_cell::sync::Lazy;
use crate::aheader::Aheader;
use crate::blob::BlobObject;
use crate::constants::{Viewtype, DC_DESIRED_TEXT_LEN, DC_ELLIPSIS};
use crate::constants::{DC_DESIRED_TEXT_LEN, DC_ELLIPSIS};
use crate::contact::{addr_normalize, ContactId};
use crate::context::Context;
use crate::dc_tools::{dc_get_filemeta, dc_truncate, parse_receive_headers};
@@ -23,7 +23,7 @@ use crate::format_flowed::unformat_flowed;
use crate::headerdef::{HeaderDef, HeaderDefMap};
use crate::key::Fingerprint;
use crate::location;
use crate::message;
use crate::message::{self, Viewtype};
use crate::param::{Param, Params};
use crate::peerstate::Peerstate;
use crate::simplify::simplify;