mirror of
https://github.com/TronoSfera/Law.git
synced 2026-05-18 10:03:45 +03:00
test new design 03
This commit is contained in:
parent
48e25dd55c
commit
00ff927dff
1 changed files with 4 additions and 1 deletions
|
|
@ -2555,7 +2555,10 @@ const NEW_REQUEST_CLIENT_OPTION = "__new_client__";
|
||||||
body: file,
|
body: file,
|
||||||
});
|
});
|
||||||
if (!putResp.ok) {
|
if (!putResp.ok) {
|
||||||
throw new Error("Не удалось загрузить файл в хранилище");
|
const errorText = (await putResp.text()).trim();
|
||||||
|
throw new Error(
|
||||||
|
`Не удалось загрузить файл в хранилище (${putResp.status}${errorText ? `: ${errorText.slice(0, 200)}` : ""})`
|
||||||
|
);
|
||||||
}
|
}
|
||||||
const done = await api("/api/admin/uploads/complete", {
|
const done = await api("/api/admin/uploads/complete", {
|
||||||
method: "POST",
|
method: "POST",
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue