Skip to content

Commit 54a650e

Browse files
remove unused waas cognito dependency (#983)
1 parent 02c6d49 commit 54a650e

4 files changed

Lines changed: 2 additions & 1126 deletions

File tree

packages/waas/package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
"@0xsequence/core": "workspace:*",
1919
"@0xsequence/network": "workspace:*",
2020
"@0xsequence/utils": "workspace:*",
21-
"@aws-sdk/client-cognito-identity-provider": "^3.445.0",
2221
"idb": "^7.1.1",
2322
"json-canonicalize": "^1.0.6",
2423
"jwt-decode": "^4.0.0"

packages/waas/src/auth.ts

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@ import {
4646
import { WaasAuthenticator, AnswerIncorrectError, Chain, EmailAlreadyInUseError, Session } from './clients/authenticator.gen'
4747
import { NoPrivateKeyError } from './errors'
4848
import { SimpleNetwork, WithSimpleNetwork } from './networks'
49-
import { EmailAuth } from './email'
5049
import { ethers } from 'ethers'
5150
import { getDefaultSubtleCryptoBackend, SubtleCryptoBackend } from './subtle-crypto'
5251
import { getDefaultSecureStoreBackend, SecureStoreBackend } from './secure-store'
@@ -177,8 +176,6 @@ export class SequenceWaaS {
177176

178177
private readonly deviceName: StoreObj<string | undefined>
179178

180-
private emailClient: EmailAuth | undefined
181-
182179
// The last Date header value returned by the server, used for users with desynchronised clocks
183180
private lastDate: Date | undefined
184181

@@ -278,23 +275,6 @@ export class SequenceWaaS {
278275
return response
279276
}
280277

281-
public get email() {
282-
if (this.emailClient) {
283-
return this.emailClient
284-
}
285-
286-
if (!this.config.emailRegion) {
287-
throw new Error('Missing emailRegion')
288-
}
289-
290-
if (!this.config.emailClientId) {
291-
throw new Error('Missing emailClientId')
292-
}
293-
294-
this.emailClient = new EmailAuth(this.config.emailRegion, this.config.emailClientId)
295-
return this.emailClient
296-
}
297-
298278
async onValidationRequired(callback: () => void) {
299279
this.validationRequiredCallback.push(callback)
300280
return () => {

packages/waas/src/email.ts

Lines changed: 0 additions & 134 deletions
This file was deleted.

0 commit comments

Comments
 (0)