Recently I've been working on a little code allowing me to connect to Office 365. It's not a really big deal, and there's a lot of options around. I wanted something of my own and something that outputs stuff I want it to output. All was going fine until I decided to move the same code that was working correctly into a separate module. Even thou commands Connect-WinExchange or Connect-WinAzureAD were executing successfully none of the commands from those sessions worked. No Get-Mailbox, no Get-MailContact. It turns out that being in another module actually puts a scope on it and therefore it's not provided when used outside of that module. I've considered two workarounds for this.