frontend: Improve file too large error (#3774)

* Improve file too large error

Signed-off-by: IThundxr <me@ithundxr.dev>

* MB -> MiB

Signed-off-by: Prospector <6166773+Prospector@users.noreply.github.com>

---------

Signed-off-by: IThundxr <me@ithundxr.dev>
Signed-off-by: Prospector <6166773+Prospector@users.noreply.github.com>
Co-authored-by: Prospector <6166773+Prospector@users.noreply.github.com>
This commit is contained in:
IThundxr 2025-06-11 22:05:30 -04:00 committed by GitHub
parent 1b1d41605b
commit d24528f6a6
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -19,7 +19,7 @@ export const useImageUpload = async (file: File, ctx: ImageUploadContext) => {
// Make sure file is less than 1MB
if (file.size > 1024 * 1024) {
throw new Error("File is too large");
throw new Error("File exceeds the 1MiB size limit");
}
const qs = new URLSearchParams();