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

Fix error not being returned properly

This commit is contained in:
dragongoose 2023-12-02 11:49:22 -05:00
parent 25d2da75b9
commit 7d7994e371
No known key found for this signature in database
GPG key ID: 01397EEC371CDAA5

View file

@ -37,11 +37,13 @@ func Routes(route *gin.Engine) {
err := context.ShouldBindJSON(&f)
if err != nil {
context.Error(err)
return
}
data, err := twitch.GetBulkStreamerInfo(f.Streamers)
if err != nil {
context.Error(err)
return
}
context.JSON(200, extractor.FormatMessage(data, true))
})