DEVELOPMENT ENVIRONMENT

~liljamo/deck-builder

f8676a87d3decf0594df9e8b6dbde7f5a50de1de — Jonni Liljamo 1 year, 8 months ago 94ad247
fix(sdbapi): simplify returns for game endpoints
2 files changed, 2 insertions(+), 2 deletions(-)

M sdbapi/handlers/allforming.go
M sdbapi/handlers/gameinfo.go
M sdbapi/handlers/allforming.go => sdbapi/handlers/allforming.go +1 -1
@@ 26,6 26,6 @@ func FormingGames(c *gin.Context) {
		return
	}

	c.JSON(http.StatusOK, gin.H{"games": games})
	c.JSON(http.StatusOK, games)
}


M sdbapi/handlers/gameinfo.go => sdbapi/handlers/gameinfo.go +1 -1
@@ 29,5 29,5 @@ func GameInfo(c *gin.Context) {
		return
	}

	c.JSON(http.StatusOK, gin.H{"id": game.ID, "state": game.State, "p1": game.P1, "p2": game.P2, "ended_at": game.EndedAt})
	c.JSON(http.StatusOK, game)
}