From 3f98b9da6eb151a57dd32a552ff639d01b5e40da Mon Sep 17 00:00:00 2001 From: Darrell Malone Jr Date: Mon, 14 Oct 2024 14:35:38 -0500 Subject: [PATCH] Update frontend user db object conections --- frontend/compositions/profile-info/index.tsx | 6 +++--- frontend/helpers/auth.tsx | 4 ++-- frontend/pages/contributor/index.tsx | 2 +- frontend/pages/passport/index.tsx | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/frontend/compositions/profile-info/index.tsx b/frontend/compositions/profile-info/index.tsx index bb9eeb727..8ebb8b1c5 100644 --- a/frontend/compositions/profile-info/index.tsx +++ b/frontend/compositions/profile-info/index.tsx @@ -13,7 +13,7 @@ export default function ProfileInfo() { const { user } = useAuth() // temp const userData = publicUser(user) - const { firstName, lastName, email, phone } = userData + const { firstname, lastname, email, phone } = userData if (editMode) { return setEditMode(false)} /> @@ -33,11 +33,11 @@ export default function ProfileInfo() {
First name:
-
{firstName}
+
{firstname}
Last name:
-
{lastName}
+
{lastname}
diff --git a/frontend/helpers/auth.tsx b/frontend/helpers/auth.tsx index 90366b4ef..b544de04d 100644 --- a/frontend/helpers/auth.tsx +++ b/frontend/helpers/auth.tsx @@ -129,8 +129,8 @@ export function setAuthForTest( user: api.User = { active: true, email: "testemail@example.com", - firstName: "FirstTest", - lastName: "LastTest", + firstname: "FirstTest", + lastname: "LastTest", role: "Public" }, accessToken: api.AccessToken = "faketoken" diff --git a/frontend/pages/contributor/index.tsx b/frontend/pages/contributor/index.tsx index 1424bb4ff..7369bca90 100644 --- a/frontend/pages/contributor/index.tsx +++ b/frontend/pages/contributor/index.tsx @@ -25,7 +25,7 @@ export default requireAuth(function Passport() { const form = useForm() const { user } = useAuth() - const userName = [user.firstName, user.lastName].filter(Boolean).join(" ") || "there" + const userName = [user.firstname, user.lastname].filter(Boolean).join(" ") || "there" const [loading, setLoading] = useState(false) const [submitError, setSubmitError] = useState(null) const [submitSuccess, setSubmitSuccess] = useState(null) diff --git a/frontend/pages/passport/index.tsx b/frontend/pages/passport/index.tsx index e528f41a9..efb87af95 100644 --- a/frontend/pages/passport/index.tsx +++ b/frontend/pages/passport/index.tsx @@ -18,7 +18,7 @@ export default requireAuth(function Passport() { const form = useForm() const { user } = useAuth() - const userName = [user.firstName, user.lastName].filter(Boolean).join(" ") || "there" + const userName = [user.firstname, user.lastname].filter(Boolean).join(" ") || "there" const [loading, setLoading] = useState(false) const [submitError, setSubmitError] = useState(null) const [submitSuccess, setSubmitSuccess] = useState(null)