Skip to content

Commit

Permalink
Update frontend user db object conections
Browse files Browse the repository at this point in the history
  • Loading branch information
DMalone87 committed Oct 14, 2024
1 parent dafb755 commit 3f98b9d
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions frontend/compositions/profile-info/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -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 <EditProfileInfo cancelEditMode={() => setEditMode(false)} />
Expand All @@ -33,11 +33,11 @@ export default function ProfileInfo() {
<main className={dataView}>
<div className={dataCell}>
<div className={label}>First name:</div>
<div className={dataField}>{firstName}</div>
<div className={dataField}>{firstname}</div>
</div>
<div className={dataCell}>
<div className={label}>Last name:</div>
<div className={dataField}>{lastName}</div>
<div className={dataField}>{lastname}</div>
</div>
<div className={dataBreak}></div>
<div className={dataCell}>
Expand Down
4 changes: 2 additions & 2 deletions frontend/helpers/auth.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -129,8 +129,8 @@ export function setAuthForTest(
user: api.User = {
active: true,
email: "[email protected]",
firstName: "FirstTest",
lastName: "LastTest",
firstname: "FirstTest",
lastname: "LastTest",
role: "Public"
},
accessToken: api.AccessToken = "faketoken"
Expand Down
2 changes: 1 addition & 1 deletion frontend/pages/contributor/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand Down
2 changes: 1 addition & 1 deletion frontend/pages/passport/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand Down

0 comments on commit 3f98b9d

Please sign in to comment.