Skip to content
This repository was archived by the owner on May 29, 2026. It is now read-only.

Commit 22b2798

Browse files
committed
fix: correct API response handling in PasskeyEntry component
- Updated the API call in the PasskeyEntry component to correctly return the disablePasswordLogin property from the response data. - Changed variable names for clarity, ensuring the data structure is accurately represented. These changes aim to improve the reliability of the authentication settings retrieval process. Signed-off-by: Innei <tukon479@gmail.com>
1 parent 564886d commit 22b2798

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

src/views/setting/tabs/account.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -935,10 +935,10 @@ const PasskeyEntry = defineComponent(() => {
935935
const { data: setting, refetch: refetchSetting } = useQuery({
936936
queryKey: queryKeys.options.detail('authSecurity'),
937937
queryFn: async () => {
938-
const data = await optionsApi.get<{
939-
disablePasswordLogin: boolean
938+
const res = await optionsApi.get<{
939+
data: { disablePasswordLogin: boolean }
940940
}>('authSecurity')
941-
return data
941+
return res.data
942942
},
943943
})
944944

0 commit comments

Comments
 (0)