mirror of
https://github.com/sot-tech/mochi.git
synced 2026-05-14 11:28:36 -07:00
fix syntactic inconsistencies
This commit is contained in:
@@ -21,8 +21,7 @@ func (t *Tracker) ServeAnnounce(w http.ResponseWriter, r *http.Request, p httpro
|
|||||||
if err == models.ErrMalformedRequest {
|
if err == models.ErrMalformedRequest {
|
||||||
fail(w, r, err)
|
fail(w, r, err)
|
||||||
return http.StatusOK
|
return http.StatusOK
|
||||||
}
|
} else if err != nil {
|
||||||
if err != nil {
|
|
||||||
return http.StatusInternalServerError
|
return http.StatusInternalServerError
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -155,7 +154,7 @@ func handleEvent(c tracker.Conn, a *models.Announce, p *models.Peer, u *models.U
|
|||||||
}
|
}
|
||||||
|
|
||||||
case t.InLeecherPool(p) && a.Left == 0:
|
case t.InLeecherPool(p) && a.Left == 0:
|
||||||
// A leecher completed but the event was never received
|
// A leecher completed but the event was never received.
|
||||||
err = tracker.LeecherFinished(c, t, p)
|
err = tracker.LeecherFinished(c, t, p)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return
|
return
|
||||||
|
|||||||
Reference in New Issue
Block a user