Remove redundant call to setCrypto (#12738)

Since matrix-org/matrix-js-sdk#4292, this thing is a no-op.
This commit is contained in:
Richard van der Hoff 2024-07-08 11:57:54 +01:00 committed by GitHub
parent 2a26afe438
commit b2a89151e6
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 0 additions and 5 deletions

View file

@ -120,7 +120,6 @@ module.exports = {
"!matrix-js-sdk/src/extensible_events_v1/InvalidEventError", "!matrix-js-sdk/src/extensible_events_v1/InvalidEventError",
"!matrix-js-sdk/src/crypto", "!matrix-js-sdk/src/crypto",
"!matrix-js-sdk/src/crypto/aes", "!matrix-js-sdk/src/crypto/aes",
"!matrix-js-sdk/src/crypto/crypto",
"!matrix-js-sdk/src/crypto/keybackup", "!matrix-js-sdk/src/crypto/keybackup",
"!matrix-js-sdk/src/crypto/deviceinfo", "!matrix-js-sdk/src/crypto/deviceinfo",
"!matrix-js-sdk/src/crypto/key_passphrase", "!matrix-js-sdk/src/crypto/key_passphrase",

View file

@ -18,7 +18,6 @@ import { Crypto } from "@peculiar/webcrypto";
import { logger } from "matrix-js-sdk/src/logger"; import { logger } from "matrix-js-sdk/src/logger";
import * as MatrixJs from "matrix-js-sdk/src/matrix"; import * as MatrixJs from "matrix-js-sdk/src/matrix";
import { decodeBase64, encodeUnpaddedBase64 } from "matrix-js-sdk/src/matrix"; import { decodeBase64, encodeUnpaddedBase64 } from "matrix-js-sdk/src/matrix";
import { setCrypto } from "matrix-js-sdk/src/crypto/crypto";
import * as MatrixCryptoAes from "matrix-js-sdk/src/crypto/aes"; import * as MatrixCryptoAes from "matrix-js-sdk/src/crypto/aes";
import { mocked, MockedObject } from "jest-mock"; import { mocked, MockedObject } from "jest-mock";
import fetchMock from "fetch-mock-jest"; import fetchMock from "fetch-mock-jest";
@ -79,7 +78,6 @@ describe("Lifecycle", () => {
delete global.localStorage; delete global.localStorage;
global.localStorage = realLocalStorage; global.localStorage = realLocalStorage;
setCrypto(webCrypto);
// @ts-ignore mocking // @ts-ignore mocking
delete window.crypto; delete window.crypto;
window.crypto = webCrypto; window.crypto = webCrypto;
@ -88,8 +86,6 @@ describe("Lifecycle", () => {
}); });
afterAll(() => { afterAll(() => {
setCrypto(windowCrypto);
// @ts-ignore unmocking // @ts-ignore unmocking
delete window.crypto; delete window.crypto;
window.crypto = windowCrypto; window.crypto = windowCrypto;