Skip to content

Commit

Permalink
refactor(bandadaapi.ts): changed the function parameter of createAler…
Browse files Browse the repository at this point in the history
…t() to show the correct message
  • Loading branch information
code-Gambler committed Feb 19, 2024
1 parent c29d122 commit fe991bd
Showing 1 changed file with 15 additions and 15 deletions.
30 changes: 15 additions & 15 deletions apps/dashboard/src/api/bandadaAPI.ts
Original file line number Diff line number Diff line change
Expand Up @@ -93,15 +93,15 @@ export async function createGroup(
name,
description,
treeDepth,
fingerprintDuration,
fingerprintDuration:null,
credentials: JSON.stringify(credentials)
}
})

return { ...group, type: "off-chain" }
} catch (error: any) {
console.error(error)
createAlert(error)
createAlert(error.response.data)
return null
}
}
Expand All @@ -124,7 +124,7 @@ export async function updateGroup(
return { ...group, type: "off-chain" }
} catch (error: any) {
console.error(error)
createAlert(error)
createAlert(error.response.data)
return null
}
}
Expand All @@ -140,7 +140,7 @@ export async function generateApiKey(groupId: string): Promise<string | null> {
})
} catch (error: any) {
console.error(error)
createAlert(error)
createAlert(error.response.data)
return null
}
}
Expand All @@ -156,7 +156,7 @@ export async function removeGroup(groupId: string): Promise<void | null> {
})
} catch (error: any) {
console.error(error)
createAlert(error)
createAlert(error.response.data)
return null
}
}
Expand Down Expand Up @@ -189,7 +189,7 @@ export async function setOAuthState(
})
} catch (error: any) {
console.error(error)
createAlert(error)
createAlert(error.response.data)
return null
}
}
Expand All @@ -213,7 +213,7 @@ export async function addMemberByCredentials(
})
} catch (error: any) {
console.error(error)
createAlert(error)
createAlert(error.response.data)
return null
}
}
Expand All @@ -233,7 +233,7 @@ export async function addMember(
})
} catch (error: any) {
console.error(error)
createAlert(error)
createAlert(error.response.data)
return null
}
}
Expand All @@ -259,7 +259,7 @@ export async function addMembers(
})
} catch (error: any) {
console.error(error)
createAlert(error)
createAlert(error.response.data)
return null
}
}
Expand All @@ -279,7 +279,7 @@ export async function removeMember(
})
} catch (error: any) {
console.error(error)
createAlert(error)
createAlert(error.response.data)
return null
}
}
Expand All @@ -305,7 +305,7 @@ export async function removeMembers(
})
} catch (error: any) {
console.error(error)
createAlert(error)
createAlert(error.response.data)
return null
}
}
Expand All @@ -321,7 +321,7 @@ export async function getNonce(): Promise<string | null> {
})
} catch (error: any) {
console.error(error)
createAlert(error)
createAlert(error.response.data)
return null
}
}
Expand Down Expand Up @@ -349,7 +349,7 @@ export async function signIn({
})
} catch (error: any) {
console.error(error)
createAlert(error)
createAlert(error.response.data)
return null
}
}
Expand All @@ -364,7 +364,7 @@ export async function logOut(): Promise<void | null> {
})
} catch (error: any) {
console.error(error)
createAlert(error)
createAlert(error.response.data)
return null
}
}
Expand All @@ -380,7 +380,7 @@ export async function isLoggedIn(): Promise<null | boolean> {
})
} catch (error: any) {
console.error(error)
createAlert(error)
createAlert(error.response.data)
return null
}
}

0 comments on commit fe991bd

Please sign in to comment.