When the second user forces the edit lock it gains the lock, which makes the upload fail for the first user because the document is now locked by the second user.
Marius Dumitru Florea on 16/Jul/25 11:04
Solved by XWIKI-22163: the quick image upload behaves like an image paste / drop now, so it uses the dedicated CKEditor upload service, which doesn't check if the document is locked.
This message was sent by Atlassian Jira (v9.3.0#930000-sha1:287aeb6)
If image attachments aren't displayed, see this article.