So, the first issue that I ran into is that the last line of the script had a specific user account called out in it and was set to enable EXO PowerShell (not disable). Therefore, I swapped that line out to: Set-User -Identity %userPrincipalName% -EXOModuleEnabled $false
.
However, I now have the following error when testing it out: 