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

Create User DataAccessObject #41

Merged
merged 3 commits into from
Jul 11, 2023
Merged

Conversation

marco-souza
Copy link
Contributor

Description

This PR Creates a DAO for the user's data

  • also fixes test cases
  • fix cyclical dependencies issue

@vercel
Copy link

vercel bot commented Jul 11, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
app ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 11, 2023 6:19pm

Copy link
Contributor

@nicolasbrandao nicolasbrandao left a comment

Choose a reason for hiding this comment

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

Pretty nice approach with the DAO class 🚢

const existingUser = await fetchUserBy({
email: loginUser.email!,
});
class UserDAO {
Copy link
Contributor

Choose a reason for hiding this comment

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

sweet, cool approach

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is cool because we can use the class as a namespace to aggregated related functions.

@marco-souza marco-souza self-assigned this Jul 11, 2023
@marco-souza marco-souza merged commit 8d96e2f into main Jul 11, 2023
@marco-souza marco-souza deleted the marco/isolate-data-access-object branch July 11, 2023 18:23
@marco-souza
Copy link
Contributor Author

@marco-souza merged this pull request with Graphite.

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.

2 participants