mirror of
https://gitlab.computer.surgery/matrix/grapevine.git
synced 2025-12-17 07:41:23 +01:00
cargo update ruma httparse
This adds authenticated media APIs.
This commit is contained in:
parent
556f2157a2
commit
5a5bea3217
5 changed files with 78 additions and 47 deletions
|
|
@ -1,6 +1,7 @@
|
|||
use std::io::Cursor;
|
||||
|
||||
use image::imageops::FilterType;
|
||||
use ruma::http_headers::ContentDisposition;
|
||||
use tokio::{
|
||||
fs::File,
|
||||
io::{AsyncReadExt, AsyncWriteExt},
|
||||
|
|
@ -35,7 +36,7 @@ impl Service {
|
|||
pub(crate) async fn create(
|
||||
&self,
|
||||
mxc: String,
|
||||
content_disposition: Option<&str>,
|
||||
content_disposition: Option<&ContentDisposition>,
|
||||
content_type: Option<&str>,
|
||||
file: &[u8],
|
||||
) -> Result<()> {
|
||||
|
|
@ -44,7 +45,7 @@ impl Service {
|
|||
mxc,
|
||||
0,
|
||||
0,
|
||||
content_disposition,
|
||||
content_disposition.map(ContentDisposition::to_string).as_deref(),
|
||||
content_type,
|
||||
)?;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue