From fb5350f445046d340ae14d35d33f29d941aa1588 Mon Sep 17 00:00:00 2001 From: Matheusafonsouza Date: Thu, 9 Jan 2025 23:22:34 -0300 Subject: [PATCH] chore: remove user id and role admin --- package-lock.json | 1 + src/hooks/useApi/index.tsx | 5 ++++- src/pages/Users/index.tsx | 2 -- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/package-lock.json b/package-lock.json index f587445..53c5104 100644 --- a/package-lock.json +++ b/package-lock.json @@ -2177,6 +2177,7 @@ }, "node_modules/@clack/prompts/node_modules/is-unicode-supported": { "version": "1.3.0", + "dev": true, "inBundle": true, "license": "MIT", "engines": { diff --git a/src/hooks/useApi/index.tsx b/src/hooks/useApi/index.tsx index eae67ea..55a13d8 100644 --- a/src/hooks/useApi/index.tsx +++ b/src/hooks/useApi/index.tsx @@ -37,7 +37,10 @@ const useApi = () => { } }> => { return new Promise((resolve) => { api - .post('/auth/signin', data) + .post('/auth/signin', { + ...data, + role: 'admin', + }) .then((res) => resolve(res)) .catch((err) => resolve(getDefaultErrorUseAPIMessage(err))); }); diff --git a/src/pages/Users/index.tsx b/src/pages/Users/index.tsx index 27c53d9..67981e0 100644 --- a/src/pages/Users/index.tsx +++ b/src/pages/Users/index.tsx @@ -38,7 +38,6 @@ function Users() { - id Nome Sobrenome Telefone @@ -50,7 +49,6 @@ function Users() { {users.map((user) => ( - {user.id} {user.firstName} {user.lastName} {user.phone}