okTurtles / group-income

A decentralized and private (end-to-end encrypted) financial safety net for you and your friends.
https://groupincome.org
GNU Affero General Public License v3.0
331 stars 44 forks source link

Multiple DMs to the same user can be created by accident #2393

Closed taoeffect closed 3 weeks ago

taoeffect commented 4 weeks ago

Problem

This can happen especially over a slow connection, like when testing on mobile with the ssh -R 80:localhost:8000 nokey@localhost.run service.

Screenshot 2024-10-23 at 12 43 34 PM

What happens is you click on a user's icon and then click the "Send message" button. It takes a while to create the new DM contract, and in that time you can press the button again, multiple times, and each time it's pressed a new DM contract to that same user will be created.

Solution

Disable this "Send message" button until the DM contract is finished creating.