Skip to main content
14 events
when toggle format what by license comment
Apr 19, 2024 at 7:20 comment added ancyrweb No, not the way I conceived this app. Also, an type of user can't evolve into another type of user, I.E an Instructor cannot become an Admin.
Apr 19, 2024 at 6:31 comment added Bart van Ingen Schenau Frame challenge: Might it be possible that one user of your application is both an Instructor and an Administrator? Or, slightly more far-fetched but usually not impossible, that one user is both an Instructor and a Student?
Apr 19, 2024 at 1:20 vote accept ancyrweb
Apr 19, 2024 at 1:13 history edited ancyrweb CC BY-SA 4.0
added 74 characters in body
Apr 19, 2024 at 1:12 comment added ancyrweb Actually it kind of make sense to have an abstract UserRepository inherited by other Account and implement a default implementation, thanks !
Apr 19, 2024 at 1:11 comment added ancyrweb @freakish just part of the exercise. There's no inherent reason for me to do it, but I want to do it as a constraint.
Apr 18, 2024 at 23:53 answer added Flater timeline score: 7
Apr 18, 2024 at 23:11 comment added Greg Burghardt On the other hand, "registration process" is the business logic in this case.
Apr 18, 2024 at 19:38 comment added Rik D I try to keep domain models focused on business logic and keep authentication out of it. Whether a user is authorized to invoke certain domain functionality is a concern for the API layer.
Apr 18, 2024 at 18:35 review Close votes
May 7, 2024 at 3:01
Apr 18, 2024 at 18:15 comment added Greg Burghardt What's wrong with having a UserRepository be the base class for other ones? You don't need a "User" entity to have a common parent class for repositories.
Apr 18, 2024 at 18:14 comment added freakish Why do you want to perform the same verification twice? Just react to the database error. It is so much more efficient (because conflict is unlikely to happen) and doesn't require additional design.
Apr 18, 2024 at 18:12 comment added Greg Burghardt What's wrong with adding a method to each repository to check the API key?
Apr 18, 2024 at 17:13 history asked ancyrweb CC BY-SA 4.0