diff options
author | hailey <hailey@blueskyweb.xyz> | 2025-08-26 17:13:11 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-08-26 17:13:11 -0700 |
commit | a1ed59e0eeb03d1f587512a1e567ebc298d71b38 (patch) | |
tree | 4c0beabb5682153bb9fbf1e3b682201ddfcdb6ca /src/screens | |
parent | 39c6984c6edabcb432ef884e7d3b12ae51a2c09e (diff) | |
download | voidsky-a1ed59e0eeb03d1f587512a1e567ebc298d71b38.tar.zst |
use an env var for configurable proxy header (#8863)
Diffstat (limited to 'src/screens')
-rw-r--r-- | src/screens/Login/ForgotPasswordForm.tsx | 6 | ||||
-rw-r--r-- | src/screens/Login/SetNewPasswordForm.tsx | 4 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/screens/Login/ForgotPasswordForm.tsx b/src/screens/Login/ForgotPasswordForm.tsx index e8582f46f..d3b5a4f10 100644 --- a/src/screens/Login/ForgotPasswordForm.tsx +++ b/src/screens/Login/ForgotPasswordForm.tsx @@ -1,7 +1,6 @@ import React, {useState} from 'react' import {ActivityIndicator, Keyboard, View} from 'react-native' -import {ComAtprotoServerDescribeServer} from '@atproto/api' -import {BskyAgent} from '@atproto/api' +import {type ComAtprotoServerDescribeServer} from '@atproto/api' import {msg, Trans} from '@lingui/macro' import {useLingui} from '@lingui/react' import * as EmailValidator from 'email-validator' @@ -9,6 +8,7 @@ import * as EmailValidator from 'email-validator' import {isNetworkError} from '#/lib/strings/errors' import {cleanError} from '#/lib/strings/errors' import {logger} from '#/logger' +import {Agent} from '#/state/session/agent' import {atoms as a, useTheme} from '#/alf' import {Button, ButtonText} from '#/components/Button' import {FormError} from '#/components/forms/FormError' @@ -55,7 +55,7 @@ export const ForgotPasswordForm = ({ setIsProcessing(true) try { - const agent = new BskyAgent({service: serviceUrl}) + const agent = new Agent(null, {service: serviceUrl}) await agent.com.atproto.server.requestPasswordReset({email}) onEmailSent() } catch (e: any) { diff --git a/src/screens/Login/SetNewPasswordForm.tsx b/src/screens/Login/SetNewPasswordForm.tsx index d2fa0f9c1..be72b558b 100644 --- a/src/screens/Login/SetNewPasswordForm.tsx +++ b/src/screens/Login/SetNewPasswordForm.tsx @@ -1,6 +1,5 @@ import {useState} from 'react' import {ActivityIndicator, View} from 'react-native' -import {BskyAgent} from '@atproto/api' import {msg, Trans} from '@lingui/macro' import {useLingui} from '@lingui/react' @@ -9,6 +8,7 @@ import {isNetworkError} from '#/lib/strings/errors' import {cleanError} from '#/lib/strings/errors' import {checkAndFormatResetCode} from '#/lib/strings/password' import {logger} from '#/logger' +import {Agent} from '#/state/session/agent' import {atoms as a, useTheme} from '#/alf' import {Button, ButtonText} from '#/components/Button' import {FormError} from '#/components/forms/FormError' @@ -63,7 +63,7 @@ export const SetNewPasswordForm = ({ setIsProcessing(true) try { - const agent = new BskyAgent({service: serviceUrl}) + const agent = new Agent(null, {service: serviceUrl}) await agent.com.atproto.server.resetPassword({ token: formattedCode, password, |