Only close groupconn/mainconn if they've been opened
Only close groupconn/mainconn if they've been opened

This fixes a crash that occured if the connection was prematurely
interrupted (i.e. from invalid password)

gempir/relaybroker