When I go onto Minecraft on my switch and login to both my Nintendo and Microsoft accounts and enter my world I go onto the pause menu to invite my friends who are playing on Xbox I get a message saying something like "Oops your Microsoft account has been disconnected, to invite more players restart the world and sign in at the main menu." Thing is when I go to the main menu both my Nintendo and Microsoft accounts are signed in and when I sign out and try to sign in again I get an error message that prevents from signing in until I restart the app. When I restart Minecraft and sign in again I get the same message in the pause menu. Sometimes it logs in properly and works but is about a one in ten chance that it will actually work and when it doesn't I just have to keep restarting until it does.
Related issues
duplicates
Comments

Thank you for your report!
We're tracking this issue in MCPE-95651, so this ticket is being resolved and linked as a duplicate.
If you would like to add a vote and any extra information to the main ticket it would be appreciated.
If you haven't already, you might like to make use of the search feature to see if the issue has already been mentioned.
Quick Links:
📓 Bug Tracker Guidelines – 💬 Community Support – 📧 Mojang Support
📓 Project Summary – ✍️ Feedback and Suggestions – 📖 Game Wiki