-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor token cache entities into types (#6580)
Refactors `CredentialEntity`, `IdTokenEntity`, `AccessTokenEntity`, and `RefreshTokenEntity` to be Types rather than a Class and moves static class methods into functions exported to the `CacheHelpers` namespace. Making these types and separating the class methods from the type definition allows us to read from the cache and directly use the value without needing to first copy each key/value pair into an instance of the class (the `toObject` helper function). Doing it this way also results in a small bundle size improvement. Reviews can be focused on the `msal-common/src/cache` folder. The rest of the changes are repetitively changing references to the affected functions
- Loading branch information
Showing
41 changed files
with
991 additions
and
1,451 deletions.
There are no files selected for viewing
7 changes: 7 additions & 0 deletions
7
change/@azure-msal-browser-f7a90af8-1831-4893-aaff-47bd8fc53621.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"type": "minor", | ||
"comment": "Refactor token cache entities to be defined as Types rather than Classes #6580", | ||
"packageName": "@azure/msal-browser", | ||
"email": "[email protected]", | ||
"dependentChangeType": "patch" | ||
} |
7 changes: 7 additions & 0 deletions
7
change/@azure-msal-common-3221a6c8-6fb8-41ed-8eb8-7ee31f61f10d.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"type": "minor", | ||
"comment": "Refactor token cache entities to be defined as Types rather than Classes #6580", | ||
"packageName": "@azure/msal-common", | ||
"email": "[email protected]", | ||
"dependentChangeType": "patch" | ||
} |
7 changes: 7 additions & 0 deletions
7
change/@azure-msal-node-14ef94d7-7234-47c0-9875-b3bb2caf75d7.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"type": "minor", | ||
"comment": "Refactor token cache entities to be defined as Types rather than Classes #6580", | ||
"packageName": "@azure/msal-node", | ||
"email": "[email protected]", | ||
"dependentChangeType": "patch" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.