microsoft / MSCloudLoginAssistant

PowerShell Module Handling Authentication to Cloud Services
https://www.powershellgallery.com/packages/MSCloudLoginAssistant/
MIT License
72 stars 47 forks source link

Fixed issues `#137` and `#138` #139

Closed bjoernf73 closed 1 year ago

bjoernf73 commented 1 year ago

The following fixes issues

137

138


This change is Reviewable

bjoernf73 commented 1 year ago

@microsoft-github-policy-service agree

ykuijs commented 1 year ago

This solution causes a Catch-22 issue: It depends on the Get-PnPContext cmdlet, which means we first have to connect to SharePoint using Connect-PnPOnline before that cmdlet works. However, we need the SPO Admin URL in order to run that cmdlet and that is exactly what we are trying to find in this code.

So I think we have to go with the solution I proposed in the issue in M365DSC. I will create a new PR, which will also fix the other issue.