External users might not be able to log in using Azure Active Directory (AD) after installing the hotfix, since their roles have been removed from the database. It affects only those roles that have been added manually.
As a solution:
<identityProviders>Note: if the "clearroleswhensignin" is set to "true", Sitecore will save roles in the database and overwrite them on every next login attempt.
<identityProvider id="SitecoreIdentityServer" type="Sitecore.Owin.Authentication.IdentityServer.IdentityServerProvider, Sitecore.Owin.Authentication.IdentityServer" resolve="true">
<caption>Go to login</caption>
<domain>sitecore</domain>
<enabled>true</enabled>
<triggerExternalSignOut>true</triggerExternalSignOut>
<clearroleswhensignin>false</clearroleswhensignin>
<transformations hint="list:AddTransformation">