Skip to content

Commit 9471c47

Browse files
committed
refactor: change async functions to synchronous in use2faApi for improved performance
1 parent ab16fbb commit 9471c47

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

custom/use2faApi.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ export const use2faApi = defineStore('2fa', () => {
3636
addEventListenerForOTPInput.value = fn;
3737
}
3838

39-
async function setCustomDialogTitle(title: string) {
39+
function setCustomDialogTitle(title: string) {
4040
customDialogTitle.value = title;
4141
}
4242

@@ -81,7 +81,7 @@ export const use2faApi = defineStore('2fa', () => {
8181
}
8282
}
8383

84-
async function get2FaConfirmationResult(title?: string, verifyingCallback?: (confirmationResult: string) => Promise<boolean> | boolean) {
84+
function get2FaConfirmationResult(title?: string, verifyingCallback?: (confirmationResult: string) => Promise<boolean> | boolean) {
8585
return new Promise(async (resolve, reject) => {
8686
if (isOpened.value) throw new Error('Modal is already open');
8787
const skipAllowModal = await checkIfSkipAllowModal();

0 commit comments

Comments
 (0)