mirror of
https://github.com/Sendouc/sendou.ink.git
synced 2026-07-14 23:33:51 -05:00
The file <input> had name="img", so new FormData(form) already included the original uncompressed file under "img". handleSubmit then appended the compressed version with the same key, and FormData.append doesn't overwrite — every save uploaded two files to S3 (the second clobbering the first under the same generated filename). The submit button also only checked the full-size img state, not smallImg. Both Compressor instances run in parallel, so Save could fire before the thumbnail finished compressing — saving art with no thumbnail, and (under slow MinIO on CI) making the e2e test flaky as two serial S3 uploads pushed past the 5s toHaveURL timeout. |
||
|---|---|---|
| .. | ||
| art.new.tsx | ||
| art.tsx | ||