Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed Edit Profile #172

Merged

Conversation

acharliekelly
Copy link
Collaborator

Closes #166. Turns out it was just missing a FormProvider, but went ahead and restructured all the Profile components so they resemble the rest of the project, with components only grouped together if they need to be. Also, the Profile is now getting data (at least user data) from the auth context instead of loading it independently from some JSON file. So it's still mock data, but at least it's the same mock data as everything else, and will therefore be able to switch to real data as soon as that becomes available.

alexjball
alexjball previously approved these changes Oct 4, 2021
Copy link
Member

@alexjball alexjball left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM except for the requireAuth

import { useAuth, requireAuth } from "../../helpers"
import styles from "./profile-type.module.css"

export default requireAuth(function ProfileType() {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The requireAuth call should wrap the whole Profile page component, so please move to pages/profile/index.tsx.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

got it, thanks

@JMStudiosJoe
Copy link
Collaborator

just need to fix conflicts then good to merge :)

@acharliekelly
Copy link
Collaborator Author

All set! Even the stories all work now!

alexjball
alexjball previously approved these changes Oct 5, 2021
@acharliekelly
Copy link
Collaborator Author

YES!!

@acharliekelly acharliekelly merged commit 7daba44 into codeforboston:main Oct 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] Edit Profile Info causes unhandled error
3 participants