diff --git a/src/Compression.ts b/src/Compression.ts index 1c4c66da6..80354cab9 100644 --- a/src/Compression.ts +++ b/src/Compression.ts @@ -4,7 +4,6 @@ import { content as proto } from '@xmtp/proto' // // Compression // - export async function decompress( encoded: proto.EncodedContent, maxSize: number diff --git a/src/keystore/SnapKeystore.ts b/src/keystore/SnapKeystore.ts index 008ac2aef..84e86911f 100644 --- a/src/keystore/SnapKeystore.ts +++ b/src/keystore/SnapKeystore.ts @@ -8,7 +8,7 @@ async function getResponse( req: Uint8Array | null, meta: SnapMeta, snapId: string -): Promise { +): Promise<(typeof apiDefs)[T]['res']> { return snapRPC(method, apiDefs[method], req, meta, snapId) } diff --git a/src/types/streams-polyfill/index.d.ts b/src/types/streams-polyfill/index.d.ts deleted file mode 100644 index 35367f242..000000000 --- a/src/types/streams-polyfill/index.d.ts +++ /dev/null @@ -1,13 +0,0 @@ -declare class DecompressionStream { - constructor(format: string) - - readonly readable: ReadableStream - readonly writable: WritableStream -} - -declare class CompressionStream { - constructor(format: string) - - readonly readable: ReadableStream - readonly writable: WritableStream -} diff --git a/src/utils/keystore.ts b/src/utils/keystore.ts index 7ac4e4433..d3ce25cfc 100644 --- a/src/utils/keystore.ts +++ b/src/utils/keystore.ts @@ -9,7 +9,7 @@ import { WithoutUndefined } from './typedefs' export const getResultOrThrow = < T extends | keystore.DecryptResponse_Response - | keystore.EncryptResponse_Response + | keystore.EncryptResponse_Response, >( response: T ): WithoutUndefined> => { diff --git a/test/keystore/persistence/EncryptedPersistence.test.ts b/test/keystore/persistence/EncryptedPersistence.test.ts index 246855314..bb6ac8c80 100644 --- a/test/keystore/persistence/EncryptedPersistence.test.ts +++ b/test/keystore/persistence/EncryptedPersistence.test.ts @@ -127,9 +127,7 @@ describe('EncryptedPersistence', () => { const goodData = SignedEciesCiphertext.fromBytes(encryptedBytes!) const signedBySomeoneElse = await SignedEciesCiphertext.create( goodData.ciphertext, - ( - await PrivateKeyBundleV1.generate() - ).identityKey + (await PrivateKeyBundleV1.generate()).identityKey ) await persistence.setItem(TEST_KEY, signedBySomeoneElse.toBytes())