moov2 / Orchard.ActiveDirectoryAuthorization

Module for Orchard CMS that handles authorization for active directory users.
19 stars 15 forks source link

Added private IUser to eliminate needless db hits. #17

Closed pope13 closed 7 years ago

pope13 commented 8 years ago

This change stores the authenticated user's userPart the first time it is fetched per request. Without this, the userPart is fetched from the DB for every call to GetAuthenticatedUser(). On pages with an already large number of database calls, this can effectively double the number of db hits and degrade performance.