The mouse remains captured if connection to a server is somehow interrupted while mouse is captured, meaning you have to restart the game manually to rejoin a server.
CoccodrillooXDS commented
I have most likely fixed it, I will push a Pull Request soon.