mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-07 19:28:09 +00:00
misc: resolved conflict with existing method
This commit is contained in:
@@ -10,6 +10,7 @@ export {
|
|||||||
useAddUserToOrg,
|
useAddUserToOrg,
|
||||||
useCreateAPIKey,
|
useCreateAPIKey,
|
||||||
useDeleteAPIKey,
|
useDeleteAPIKey,
|
||||||
|
useDeleteMe,
|
||||||
useDeleteOrgMembership,
|
useDeleteOrgMembership,
|
||||||
useGetMyAPIKeys,
|
useGetMyAPIKeys,
|
||||||
useGetMyAPIKeysV2,
|
useGetMyAPIKeysV2,
|
||||||
|
|||||||
@@ -49,7 +49,7 @@ export const fetchUsersList = async () => {
|
|||||||
|
|
||||||
export const useListUsers = () => useQuery(userKeys.listUsers, fetchUsersList);
|
export const useListUsers = () => useQuery(userKeys.listUsers, fetchUsersList);
|
||||||
|
|
||||||
export const useDeleteUser = () => {
|
export const useDeleteMe = () => {
|
||||||
const queryClient = useQueryClient();
|
const queryClient = useQueryClient();
|
||||||
|
|
||||||
return useMutation({
|
return useMutation({
|
||||||
|
|||||||
+3
-3
@@ -2,17 +2,17 @@ import { useRouter } from "next/router";
|
|||||||
|
|
||||||
import { createNotification } from "@app/components/notifications";
|
import { createNotification } from "@app/components/notifications";
|
||||||
import { Button, DeleteActionModal } from "@app/components/v2";
|
import { Button, DeleteActionModal } from "@app/components/v2";
|
||||||
import { useDeleteUser } from "@app/hooks/api";
|
import { useDeleteMe } from "@app/hooks/api";
|
||||||
import { usePopUp } from "@app/hooks/usePopUp";
|
import { usePopUp } from "@app/hooks/usePopUp";
|
||||||
|
|
||||||
export const DeleteAccountSection = () => {
|
export const DeleteAccountSection = () => {
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
|
|
||||||
const { popUp, handlePopUpOpen, handlePopUpClose, handlePopUpToggle } = usePopUp([
|
const { popUp, handlePopUpOpen, handlePopUpClose, handlePopUpToggle } = usePopUp([
|
||||||
"deleteAccount"
|
"deleteAccount"
|
||||||
] as const);
|
] as const);
|
||||||
|
|
||||||
const { mutateAsync: deleteUserMutateAsync, isLoading } = useDeleteUser();
|
const { mutateAsync: deleteUserMutateAsync, isLoading } = useDeleteMe();
|
||||||
|
|
||||||
const handleDeleteAccountSubmit = async () => {
|
const handleDeleteAccountSubmit = async () => {
|
||||||
try {
|
try {
|
||||||
|
|||||||
Reference in New Issue
Block a user