0
Fork 0
mirror of https://codeberg.org/SafeTwitch/safetwitch-backend.git synced 2024-12-22 05:02:58 -05:00

Remove all the 301 errors

This commit is contained in:
dragongoose 2023-06-07 12:25:52 -04:00
parent f3afc56f2c
commit 3c3341fb65
No known key found for this signature in database
GPG key ID: 50DB99B921579009
3 changed files with 3 additions and 3 deletions

View file

@ -10,7 +10,7 @@ import (
func Routes(route *gin.Engine) {
auth := route.Group("/api/badges")
auth.GET("/", func(context *gin.Context) {
auth.GET("", func(context *gin.Context) {
query := context.Query("streamerName")
if query != "" {
data, err := twitch.GetStreamerBadges(query)

View file

@ -10,7 +10,7 @@ import (
func Routes(route *gin.Engine) {
auth := route.Group("/api/discover")
auth.GET("/", func(context *gin.Context) {
auth.GET("", func(context *gin.Context) {
data, err := twitch.GetDiscoveryPage(50, "")
if err != nil {
context.Error(err)

View file

@ -10,7 +10,7 @@ import (
func Routes(route *gin.Engine) {
auth := route.Group("/")
auth.GET("/", func(context *gin.Context) {
auth.GET("", func(context *gin.Context) {
upgradeHeader := context.Request.Header.Get("Upgrade")
if upgradeHeader == "websocket" {
chat.ServeWS(context)