Chore: solved some todos

This commit is contained in:
Grail Finder
2025-06-12 07:04:20 +03:00
parent 6934b724ae
commit 74b10b8395
10 changed files with 50 additions and 82 deletions

View File

@ -183,17 +183,6 @@ func cacheSetSession(key string, session *models.Session) error {
return err
}
memcache.Set(key, sesb)
// TODO: to config
memcache.Expire(key, 60*60)
memcache.Expire(key, cfg.SessionLifetime)
return nil
}
// unused
// func updateRoomInSession(ctx context.Context, roomID string) (context.Context, error) {
// s, ok := ctx.Value(models.CtxSessionKey).(*models.Session)
// if !ok {
// return context.TODO(), errors.New("failed to extract session from ctx")
// }
// s.CurrentRoom = roomID
// return context.WithValue(ctx, "session", s), nil
// }