Skip to content

Commit 063b4ed

Browse files
- Fix lint issues.
1 parent 5c7c40b commit 063b4ed

9 files changed

Lines changed: 14 additions & 33 deletions

File tree

lib/msal-browser/src/cache/BrowserCacheManager.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1021,10 +1021,7 @@ export class BrowserCacheManager extends CacheManager {
10211021
* @param correlationId {string} correlation id
10221022
* @returns
10231023
*/
1024-
async clearTokensAndKeysWithClaims(
1025-
performanceClient: IPerformanceClient,
1026-
correlationId: string
1027-
): Promise<void> {
1024+
async clearTokensAndKeysWithClaims(): Promise<void> {
10281025
const tokenKeys = this.getTokenKeys();
10291026

10301027
const removedAccessTokens: Array<Promise<void>> = [];

lib/msal-browser/src/controllers/StandardController.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -387,7 +387,7 @@ export class StandardController implements IController {
387387
this.logger,
388388
this.performanceClient,
389389
initCorrelationId
390-
)(this.performanceClient, initCorrelationId);
390+
)();
391391
}
392392

393393
if (

lib/msal-browser/src/crypto/BrowserCrypto.ts

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,6 @@ import {
77
createBrowserAuthError,
88
BrowserAuthErrorCodes,
99
} from "../error/BrowserAuthError.js";
10-
import {
11-
IPerformanceClient,
12-
PerformanceEvents,
13-
} from "@azure/msal-common/browser";
1410
import { KEY_FORMAT_JWK } from "../utils/BrowserConstants.js";
1511
import { base64Encode, urlEncodeArr } from "../encode/Base64Encode.js";
1612
import { base64Decode, base64DecToArr } from "../encode/Base64Decode.js";
@@ -84,9 +80,7 @@ export function validateCryptoAvailable(
8480
* @param correlationId {?string} correlation id
8581
*/
8682
export async function sha256Digest(
87-
dataString: string,
88-
performanceClient?: IPerformanceClient,
89-
correlationId?: string
83+
dataString: string
9084
): Promise<ArrayBuffer> {
9185
const encoder = new TextEncoder();
9286
const data = encoder.encode(dataString);

lib/msal-browser/src/crypto/PkceGenerator.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ async function generateCodeChallengeFromVerifier(
9898
logger,
9999
performanceClient,
100100
correlationId
101-
)(pkceCodeVerifier, performanceClient, correlationId);
101+
)(pkceCodeVerifier);
102102
// encode hash as base64
103103
return urlEncodeArr(new Uint8Array(pkceHashedCodeVerifier));
104104
} catch (e) {

lib/msal-browser/src/protocol/Authorize.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -453,8 +453,7 @@ export async function handleResponseEAR(
453453
new CryptoOps(logger, performanceClient),
454454
logger,
455455
null,
456-
null,
457-
performanceClient
456+
null
458457
);
459458

460459
// Validate response. This function throws a server error if an error is returned by the server.

lib/msal-browser/test/cache/BrowserCacheManager.spec.ts

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -909,14 +909,8 @@ describe("BrowserCacheManager tests", () => {
909909
)
910910
).toEqual(testAT4);
911911

912-
browserSessionStorage.clearTokensAndKeysWithClaims(
913-
getDefaultPerformanceClient(),
914-
"test-correlation-id"
915-
);
916-
browserLocalStorage.clearTokensAndKeysWithClaims(
917-
getDefaultPerformanceClient(),
918-
"test-correlation-id"
919-
);
912+
browserSessionStorage.clearTokensAndKeysWithClaims();
913+
browserLocalStorage.clearTokensAndKeysWithClaims();
920914

921915
expect(
922916
browserSessionStorage.getAccessTokenCredential(

lib/msal-common/apiReview/msal-common.api.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3505,7 +3505,7 @@ const RESPONSE_TYPE = "response_type";
35053505
//
35063506
// @internal
35073507
export class ResponseHandler {
3508-
constructor(clientId: string, cacheStorage: CacheManager, cryptoObj: ICrypto, logger: Logger, serializableCache: ISerializableTokenCache | null, persistencePlugin: ICachePlugin | null, performanceClient?: IPerformanceClient);
3508+
constructor(clientId: string, cacheStorage: CacheManager, cryptoObj: ICrypto, logger: Logger, serializableCache: ISerializableTokenCache | null, persistencePlugin: ICachePlugin | null);
35093509
// Warning: (tsdoc-undefined-tag) The TSDoc tag "@AuthenticationResult" is not defined in this configuration
35103510
// Warning: (tsdoc-undefined-tag) The TSDoc tag "@CacheRecord" is not defined in this configuration
35113511
// Warning: (tsdoc-undefined-tag) The TSDoc tag "@IdToken" is not defined in this configuration
@@ -4247,10 +4247,10 @@ const X_MS_LIB_CAPABILITY = "x-ms-lib-capability";
42474247
// src/cache/CacheManager.ts:1827:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen
42484248
// src/cache/utils/CacheTypes.ts:94:53 - (tsdoc-escape-greater-than) The ">" character should be escaped using a backslash to avoid confusion with an HTML tag
42494249
// src/cache/utils/CacheTypes.ts:94:43 - (tsdoc-malformed-html-name) Invalid HTML element: An HTML name must be an ASCII letter followed by zero or more letters, digits, or hyphens
4250+
// src/client/AuthorizationCodeClient.ts:152:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen
42504251
// src/client/AuthorizationCodeClient.ts:153:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen
4251-
// src/client/AuthorizationCodeClient.ts:154:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen
4252-
// src/client/AuthorizationCodeClient.ts:211:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen
4253-
// src/client/AuthorizationCodeClient.ts:438:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen
4252+
// src/client/AuthorizationCodeClient.ts:210:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen
4253+
// src/client/AuthorizationCodeClient.ts:437:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen
42544254
// src/client/RefreshTokenClient.ts:183:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen
42554255
// src/client/RefreshTokenClient.ts:271:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen
42564256
// src/client/RefreshTokenClient.ts:272:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen
@@ -4261,9 +4261,9 @@ const X_MS_LIB_CAPABILITY = "x-ms-lib-capability";
42614261
// src/index.ts:8:12 - (tsdoc-characters-after-block-tag) The token "@azure" looks like a TSDoc tag but contains an invalid character "/"; if it is not a tag, use a backslash to escape the "@"
42624262
// src/index.ts:8:4 - (tsdoc-undefined-tag) The TSDoc tag "@module" is not defined in this configuration
42634263
// src/request/AuthenticationHeaderParser.ts:74:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen
4264+
// src/response/ResponseHandler.ts:326:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen
4265+
// src/response/ResponseHandler.ts:327:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen
42644266
// src/response/ResponseHandler.ts:328:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen
4265-
// src/response/ResponseHandler.ts:329:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen
4266-
// src/response/ResponseHandler.ts:330:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen
42674267
// src/telemetry/performance/PerformanceClient.ts:692:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen
42684268
// src/telemetry/performance/PerformanceClient.ts:692:15 - (tsdoc-param-tag-with-invalid-type) The @param block should not include a JSDoc-style '{type}'
42694269
// src/telemetry/performance/PerformanceClient.ts:704:8 - (tsdoc-param-tag-missing-hyphen) The @param block should be followed by a parameter name and then a hyphen

lib/msal-common/src/client/AuthorizationCodeClient.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,6 @@ export class AuthorizationCodeClient extends BaseClient {
102102
this.logger,
103103
this.config.serializableCache,
104104
this.config.persistencePlugin,
105-
this.performanceClient
106105
);
107106

108107
// Validate response. This function throws a server error if an error is returned by the server.

lib/msal-common/src/response/ResponseHandler.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@ import { TokenCacheContext } from "../cache/persistence/TokenCacheContext.js";
3838
import { ISerializableTokenCache } from "../cache/interface/ISerializableTokenCache.js";
3939
import { AuthorizationCodePayload } from "./AuthorizationCodePayload.js";
4040
import { BaseAuthRequest } from "../request/BaseAuthRequest.js";
41-
import { IPerformanceClient } from "../telemetry/performance/IPerformanceClient.js";
4241
import { checkMaxAge, extractTokenClaims } from "../account/AuthToken.js";
4342
import {
4443
TokenClaims,
@@ -72,8 +71,7 @@ export class ResponseHandler {
7271
cryptoObj: ICrypto,
7372
logger: Logger,
7473
serializableCache: ISerializableTokenCache | null,
75-
persistencePlugin: ICachePlugin | null,
76-
performanceClient?: IPerformanceClient
74+
persistencePlugin: ICachePlugin | null
7775
) {
7876
this.clientId = clientId;
7977
this.cacheStorage = cacheStorage;

0 commit comments

Comments
 (0)