Skip to content

Commit 502d482

Browse files
committed
fix: blacklist name
1 parent cff83e4 commit 502d482

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

server/activity.go

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -122,14 +122,7 @@ func (s *Server) RemoveActivity(c *gin.Context) (interface{}, error) {
122122
}
123123

124124
func (s *Server) addTorrent2Blacklist(h *ent.History) error {
125-
var name string
126-
127-
task, ok := s.core.GetTask(h.ID)
128-
if ok {
129-
name, _ = task.Name()
130-
}
131-
132-
return s.db.AddTorrent2Blacklist(h.Hash, name, h.MediaID)
125+
return s.db.AddTorrent2Blacklist(h.Hash, h.SourceTitle, h.MediaID)
133126
}
134127

135128
func (s *Server) GetAllBlacklistItems(c *gin.Context) (interface{}, error) {

0 commit comments

Comments
 (0)