Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeError in getRootMicrosoftGraphUri #215

Open
Loki3000 opened this issue Sep 21, 2024 · 2 comments
Open

TypeError in getRootMicrosoftGraphUri #215

Loki3000 opened this issue Sep 21, 2024 · 2 comments

Comments

@Loki3000
Copy link

Hi there!

        $openIdConfiguration = $this->getOpenIdConfiguration($tenant, $version);
        return 'https://' . $openIdConfiguration['msgraph_host'];

After an unsuccessful attempt to get the configuration, getOpenIdConfiguration returns an empty string.
As a result, the next line triggers a TypeError. It's not an exception, so it isn't caught by other error handlers.

@decomplexity
Copy link

The statement is correct (is in use here every day) - so it is worth checking your $tenant and $version

@Loki3000
Copy link
Author

Possible return types of getOpenIdConfiguration is array|string (string in case of BadResponseException)
in case of string statement $openIdConfiguration['msgraph_host'] is not correct

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants