feat: create room endpoint

not really sets the cookie, but returns the rendered index on success
This commit is contained in:
efim
2023-10-30 05:19:43 +00:00
parent 201b3760da
commit 850b6c693b
2 changed files with 46 additions and 6 deletions

View File

@@ -68,6 +68,6 @@ func (redisRM RedisRM) Get(roomName string) (Room, bool, error) {
}
func (redisRM RedisRM) Save(room Room) error {
err := redisRM.Rdb.Set(ctx, roomNameToRedisId(room.Name), room, 0).Err() // maybe even set expiration?
err := redisRM.Rdb.Set(ctx, roomNameToRedisId(room.Name), &room, 0).Err() // maybe even set expiration?
return err
}