This commit is contained in:
Manav Rathi
2024-06-05 15:00:08 +05:30
parent b987f80ee5
commit 9ee4ab4cc0
3 changed files with 8 additions and 7 deletions

View File

@@ -33,11 +33,11 @@ import {
useState,
} from "react";
import { deletePasskey, renamePasskey } from "services/passkeysService";
import type { Passkey } from "types/passkey";
import {
finishPasskeyRegistration,
getPasskeyRegistrationOptions,
getPasskeys,
type Passkey,
} from "../../services/passkeysService";
export const PasskeysContext = createContext(

View File

@@ -6,6 +6,13 @@ import _sodium from "libsodium-wrappers";
const ENDPOINT = getEndpoint();
export interface Passkey {
id: string;
userID: number;
friendlyName: string;
createdAt: number;
}
export const getPasskeys = async () => {
try {
const token = getToken();

View File

@@ -1,6 +0,0 @@
export interface Passkey {
id: string;
userID: number;
friendlyName: string;
createdAt: number;
}