Minor fix to new torrent fetcher.

This commit is contained in:
Dessalines 2019-02-07 16:10:26 -08:00
parent 8e5ab798e9
commit 5494e87cdd
2 changed files with 2 additions and 1 deletions

1
.gitignore vendored
View File

@ -3,3 +3,4 @@ old_greps.sh
torrents.db torrents.db
.vscode .vscode
backups backups
torrents

View File

@ -47,7 +47,6 @@ fn main() {
leetx(save_dir); leetx(save_dir);
skytorrents(save_dir); skytorrents(save_dir);
if let Some(t) = matches.value_of("TORRENTS_CSV_FILE") { if let Some(t) = matches.value_of("TORRENTS_CSV_FILE") {
torrents_csv_scan(Path::new(t), save_dir); torrents_csv_scan(Path::new(t), save_dir);
} }
@ -62,6 +61,7 @@ fn torrents_csv_scan(torrents_csv_file: &Path, save_dir: &Path) {
fn collect_info_hashes(torrents_csv_file: &Path) -> Vec<String> { fn collect_info_hashes(torrents_csv_file: &Path) -> Vec<String> {
println!("Scanning torrent infohashes..."); println!("Scanning torrent infohashes...");
let mut rdr = csv::ReaderBuilder::new() let mut rdr = csv::ReaderBuilder::new()
.has_headers(false)
.delimiter(b';') .delimiter(b';')
.from_path(torrents_csv_file) .from_path(torrents_csv_file)
.unwrap(); .unwrap();