mirror of
https://github.com/muety/wakapi.git
synced 2023-08-10 21:12:56 +03:00
Refactor to server-rendered app.
This commit is contained in:
@ -10,6 +10,8 @@ type UserService struct {
|
||||
Db *gorm.DB
|
||||
}
|
||||
|
||||
func (srv *UserService) Init() {}
|
||||
|
||||
func (srv *UserService) GetUserById(userId string) (*models.User, error) {
|
||||
u := &models.User{}
|
||||
if err := srv.Db.Where(&models.User{ID: userId}).First(u).Error; err != nil {
|
||||
|
Reference in New Issue
Block a user