allow to delete torrents

This commit is contained in:
2026-02-12 23:34:53 +03:00
parent 155cb3e726
commit 738917979e
4 changed files with 59 additions and 1 deletions

View File

@@ -41,3 +41,8 @@ func (m *Model) GetTorrentByGuidAndItemId(guid string, itemId int64) (*Torrent,
return torrent, nil
}
func (m *Model) DeleteTorrentById(torrentId int64) error {
_, err := m.db.Exec("DELETE FROM torrents WHERE id = ?", torrentId)
return err
}