associate the user id with the session

This commit is contained in:
Asim Aslam
2021-08-16 15:55:36 +01:00
parent fe3fb4f84a
commit c76eba1d75
3 changed files with 173 additions and 149 deletions

View File

@@ -200,6 +200,7 @@ func (s *User) Login(ctx context.Context, req *pb.LoginRequest, rsp *pb.LoginRes
Id: random(128),
Created: time.Now().Unix(),
Expires: time.Now().Add(time.Hour * 24 * 7).Unix(),
UserId: accounts[0].Id,
}
if err := s.domain.CreateSession(ctx, sess); err != nil {