feat: support 2fA

This commit is contained in:
kawamataryo
2024-10-19 10:55:10 +09:00
parent 7e79d62a10
commit 1df5e2ba76
5 changed files with 12 additions and 3 deletions

View File

@@ -196,10 +196,12 @@ export const useRetrieveBskyUsers = () => {
identifier,
password,
messageName,
authFactorToken,
}: {
identifier: string;
password: string;
messageName: (typeof MESSAGE_NAMES)[keyof typeof MESSAGE_NAMES];
authFactorToken?: string;
}) => {
setRetrievalParams({
identifier,
@@ -210,6 +212,7 @@ export const useRetrieveBskyUsers = () => {
bskyClient.current = await BskyServiceWorkerClient.createAgent({
identifier,
password,
...(authFactorToken && { authFactorToken: authFactorToken }),
});
setActionMode(MESSAGE_NAME_TO_ACTION_MODE_MAP[messageName]);