mirror of
https://github.com/idanoo/autobrr
synced 2025-07-23 08:49:13 +00:00
parent
89cf68e773
commit
d380c0b178
5 changed files with 43 additions and 30 deletions
|
@ -149,12 +149,9 @@ func (s *service) CheckActionPreconditions(ctx context.Context, action *domain.A
|
|||
}
|
||||
|
||||
if action.CheckMacrosNeedRawDataBytes(release) {
|
||||
tmpFile, err := os.ReadFile(release.TorrentTmpFile)
|
||||
if err != nil {
|
||||
return errors.Wrap(err, "could not read torrent file: %v", release.TorrentTmpFile)
|
||||
if err := release.OpenTorrentFile(); err != nil {
|
||||
return errors.Wrap(err, "could not open torrent file for release: %s", release.TorrentName)
|
||||
}
|
||||
|
||||
release.TorrentDataRawBytes = tmpFile
|
||||
}
|
||||
|
||||
return nil
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue