change no auth status

This commit is contained in:
YouROK
2021-04-14 16:58:21 +03:00
parent 514b9591a2
commit dfbbad21d0

View File

@@ -156,7 +156,8 @@ func streamNoAuth(c *gin.Context) {
tor := torr.GetTorrent(spec.InfoHash.HexString())
if tor == nil {
c.AbortWithStatus(http.StatusForbidden)
c.Header("WWW-Authenticate", "Basic realm=Authorization Required")
c.AbortWithStatus(http.StatusUnauthorized)
return
}