forked from torrust/torrust-index
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: [torrust#242] wrong infohash when info dict contains source field
When you define a "source" field value in the "info" dictionary inside the torrent file the field changes the infohash value. We did not save that field in the database and in the in-memory struct `TorrentInfo` so the calculated infohash was wrong becuase this field belongs to the `info` key.
- Loading branch information
1 parent
27354a4
commit c3e61ea
Showing
6 changed files
with
10 additions
and
2 deletions.
There are no files selected for viewing
1 change: 1 addition & 0 deletions
1
migrations/mysql/20230803160604_torrust_torrents_add_source.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ALTER TABLE torrust_torrents ADD COLUMN source TEXT DEFAULT NULL |
1 change: 1 addition & 0 deletions
1
migrations/sqlite3/20230803160604_torrust_torrents_add_source.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ALTER TABLE torrust_torrents ADD COLUMN source TEXT DEFAULT NULL |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters