From 47c6253398189ad764b935e6385c61de76b5e67d Mon Sep 17 00:00:00 2001 From: Matthias Veit Date: Mon, 23 Sep 2024 13:56:55 +0200 Subject: [PATCH] [core][fix] Multipart name (#2203) --- fixcore/fixcore/web/api.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fixcore/fixcore/web/api.py b/fixcore/fixcore/web/api.py index d331eb2dc3..245832f64a 100644 --- a/fixcore/fixcore/web/api.py +++ b/fixcore/fixcore/web/api.py @@ -1389,7 +1389,7 @@ async def write_files(mpr: MultipartReader, tmp_dir: str) -> Dict[str, str]: if isinstance(part, MultipartReader): files.update(await write_files(part, tmp_dir)) elif isinstance(part, BodyPartReader): - name = part.filename + name = part.name if not name: raise AttributeError("Multipart request: content disposition name is required!") path = os.path.join(tmp_dir, rnd_str()) # use random local path to avoid clashes