Skip to content

Commit

Permalink
fix: remove console logs
Browse files Browse the repository at this point in the history
  • Loading branch information
J0 committed Sep 30, 2024
1 parent e5be238 commit 72a7e9e
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 2,857 deletions.
14 changes: 0 additions & 14 deletions src/GoTrueClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2428,22 +2428,16 @@ export default class GoTrueClient {
rpOrigins: rpOrigins,
}

console.log(rpOrigins)
console.log('after here')

const { data: challengeData, error: challengeError } = await this._challenge({
factorId,
webAuthn,
})
if (challengeError) {
return { data: null, error: challengeError }
}
console.log('no challenge error')
if (!challengeData) {
return { data: null, error: new Error('Challenge data or options are null') }
}
console.log('challeng data')
console.log(challengeData)
if (!(challengeData.type === 'webauthn' && challengeData?.credential_creation_options)) {
return { data: null, error: new Error('Invalid challenge data for WebAuthn') }
}
Expand All @@ -2453,7 +2447,6 @@ export default class GoTrueClient {
throw new Error('Invalid challenge options')
}

console.log(challengeOptions)
const publicKey: PublicKeyCredentialCreationOptions = {
...challengeOptions,
challenge: base64URLStringToBuffer(challengeOptions.challenge),
Expand All @@ -2480,8 +2473,6 @@ export default class GoTrueClient {
if (typeof response.getTransports === 'function') {
transports = response.getTransports()
}
console.log('in credenital')
console.log(credential)
// L3 says this is required, but browser and webview support are still not guaranteed.
let responsePublicKeyAlgorithm: number | undefined = undefined
if (typeof response.getPublicKeyAlgorithm === 'function') {
Expand Down Expand Up @@ -2538,7 +2529,6 @@ export default class GoTrueClient {
webAuthn: verifyWebAuthnParams,
})
} catch (credentialError) {
console.log(credentialError)
return {
data: null,
error: new Error(`Credential creation failed: ${credentialError}`),
Expand Down Expand Up @@ -2572,7 +2562,6 @@ export default class GoTrueClient {
const webauthn = factors.filter(
(factor) => factor.factor_type === 'webauthn' && factor.status === 'verified'
)
console.log(factors)

webAuthnFactor = webauthn[0]
//
Expand Down Expand Up @@ -2762,7 +2751,6 @@ export default class GoTrueClient {
body = {
web_authn: { rp_id: params.webAuthn.rpId, rp_origins: params.webAuthn.rpOrigins },
}
console.log('can call chlalneg')
return await this._useSession(async (result) => {
const { data: sessionData, error: sessionError } = result
if (sessionError) {
Expand Down Expand Up @@ -2847,8 +2835,6 @@ export default class GoTrueClient {
*/
private async _listFactors(): Promise<AuthMFAListFactorsResponse> {
// use #getUser instead of #_getUser as the former acquires a lock
console.log(this.lockAcquired)
console.log(this.pendingInLock)
try {
const {
data: { user },
Expand Down
Loading

0 comments on commit 72a7e9e

Please sign in to comment.