mirror of
https://github.com/sot-tech/mochi.git
synced 2026-05-13 08:48:35 -07:00
tracker: fix reference to config
This commit is contained in:
@@ -27,7 +27,7 @@ func (tkr *Tracker) HandleAnnounce(ann *models.Announce, w Writer) (err error) {
|
|||||||
|
|
||||||
torrent, err := tkr.FindTorrent(ann.Infohash)
|
torrent, err := tkr.FindTorrent(ann.Infohash)
|
||||||
|
|
||||||
if err == models.ErrTorrentDNE && cfg.CreateOnAnnounce {
|
if err == models.ErrTorrentDNE && tkr.Config.CreateOnAnnounce {
|
||||||
torrent = &models.Torrent{
|
torrent = &models.Torrent{
|
||||||
Infohash: ann.Infohash,
|
Infohash: ann.Infohash,
|
||||||
Seeders: models.NewPeerMap(true, tkr.Config),
|
Seeders: models.NewPeerMap(true, tkr.Config),
|
||||||
|
|||||||
Reference in New Issue
Block a user