Skip to content
New issue

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

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

Already on GitHub? # to your account

#159: Differentiate Between BaseUser and User #288

Conversation

AlesSust
Copy link
Contributor

@AlesSust AlesSust commented Nov 10, 2024

Description

Differentiate between BaseUser and User by creating a Base class for all users and a User class that implements it, just like Artist is doing it at the moment.

Commit type

  • refactor: refactoring production code, eg. renaming a variable.

Issue

#159

Solution

The solution involves restructuring the User class hierarchy by creating a new BaseUser class to serve as a common base for all user types. The User class now extends BaseUser, aligning with the existing structure of the Artist class.

Proposed Changes

-created BaseUser
-modified User to inherit from BaseUser
-changed type annotations from User to BaseUser

Potential Impact

This change could affect any existing functionality that directly references the User class. Potential risks include compatibility issues in methods expecting a User instance but now receiving BaseUser. Careful testing and updates to type annotations will be essential to minimize side effects.

Additional Tasks

  • Update documentation to reflect the new BaseUser and User class structure.
  • Add tests for BaseUser and User to verify that inheritance and functionality work as expected.
  • Update any dependencies or services that rely on the User class to use BaseUser where applicable.

Assigned

@AntonioMrtz

@AlesSust
Copy link
Contributor Author

Still need to add:
-tests
-improve coverage

@AntonioMrtz AntonioMrtz linked an issue Nov 14, 2024 that may be closed by this pull request
@AntonioMrtz AntonioMrtz merged commit 026bbaa into AntonioMrtz:master Dec 1, 2024
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Differentiate between BaseUser and User
2 participants