When SOGo is launched from an external link, either using a different "target" or using window.open(), the Mail composer could throw a JavaScript exception when trying to save or send a message that would completely stop the operation. Fixes #3900