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:
parent
f3afc56f2c
commit
3c3341fb65
3 changed files with 3 additions and 3 deletions
|
@ -10,7 +10,7 @@ import (
|
||||||
func Routes(route *gin.Engine) {
|
func Routes(route *gin.Engine) {
|
||||||
auth := route.Group("/api/badges")
|
auth := route.Group("/api/badges")
|
||||||
|
|
||||||
auth.GET("/", func(context *gin.Context) {
|
auth.GET("", func(context *gin.Context) {
|
||||||
query := context.Query("streamerName")
|
query := context.Query("streamerName")
|
||||||
if query != "" {
|
if query != "" {
|
||||||
data, err := twitch.GetStreamerBadges(query)
|
data, err := twitch.GetStreamerBadges(query)
|
||||||
|
|
|
@ -10,7 +10,7 @@ import (
|
||||||
func Routes(route *gin.Engine) {
|
func Routes(route *gin.Engine) {
|
||||||
auth := route.Group("/api/discover")
|
auth := route.Group("/api/discover")
|
||||||
|
|
||||||
auth.GET("/", func(context *gin.Context) {
|
auth.GET("", func(context *gin.Context) {
|
||||||
data, err := twitch.GetDiscoveryPage(50, "")
|
data, err := twitch.GetDiscoveryPage(50, "")
|
||||||
if err != nil {
|
if err != nil {
|
||||||
context.Error(err)
|
context.Error(err)
|
||||||
|
|
|
@ -10,7 +10,7 @@ import (
|
||||||
func Routes(route *gin.Engine) {
|
func Routes(route *gin.Engine) {
|
||||||
auth := route.Group("/")
|
auth := route.Group("/")
|
||||||
|
|
||||||
auth.GET("/", func(context *gin.Context) {
|
auth.GET("", func(context *gin.Context) {
|
||||||
upgradeHeader := context.Request.Header.Get("Upgrade")
|
upgradeHeader := context.Request.Header.Get("Upgrade")
|
||||||
if upgradeHeader == "websocket" {
|
if upgradeHeader == "websocket" {
|
||||||
chat.ServeWS(context)
|
chat.ServeWS(context)
|
||||||
|
|
Loading…
Reference in a new issue