@@ -474,9 +474,6 @@ pub struct Tracker {
474
474
/// The tracker configuration.
475
475
config : Core ,
476
476
477
- /// The service to check is a torrent is whitelisted.
478
- _whitelist_authorization : Arc < whitelist:: authorization:: Authorization > ,
479
-
480
477
/// The in-memory torrents repository.
481
478
in_memory_torrent_repository : Arc < InMemoryTorrentRepository > ,
482
479
@@ -534,13 +531,11 @@ impl Tracker {
534
531
/// Will return a `databases::error::Error` if unable to connect to database. The `Tracker` is responsible for the persistence.
535
532
pub fn new (
536
533
config : & Core ,
537
- whitelist_authorization : & Arc < whitelist:: authorization:: Authorization > ,
538
534
in_memory_torrent_repository : & Arc < InMemoryTorrentRepository > ,
539
535
db_torrent_repository : & Arc < DatabasePersistentTorrentRepository > ,
540
536
) -> Result < Tracker , databases:: error:: Error > {
541
537
Ok ( Tracker {
542
538
config : config. clone ( ) ,
543
- _whitelist_authorization : whitelist_authorization. clone ( ) ,
544
539
in_memory_torrent_repository : in_memory_torrent_repository. clone ( ) ,
545
540
db_torrent_repository : db_torrent_repository. clone ( ) ,
546
541
} )
@@ -719,7 +714,6 @@ mod tests {
719
714
720
715
let tracker = Arc :: new ( initialize_tracker (
721
716
& config,
722
- & whitelist_authorization,
723
717
& in_memory_torrent_repository,
724
718
& db_torrent_repository,
725
719
) ) ;
@@ -735,7 +729,7 @@ mod tests {
735
729
let (
736
730
_database,
737
731
_in_memory_whitelist,
738
- whitelist_authorization ,
732
+ _whitelist_authorization ,
739
733
_authentication_service,
740
734
in_memory_torrent_repository,
741
735
db_torrent_repository,
@@ -744,7 +738,6 @@ mod tests {
744
738
745
739
let tracker = Arc :: new ( initialize_tracker (
746
740
& config,
747
- & whitelist_authorization,
748
741
& in_memory_torrent_repository,
749
742
& db_torrent_repository,
750
743
) ) ;
@@ -772,12 +765,7 @@ mod tests {
772
765
773
766
let whitelist_manager = initialize_whitelist_manager ( database. clone ( ) , in_memory_whitelist. clone ( ) ) ;
774
767
775
- let tracker = initialize_tracker (
776
- & config,
777
- & whitelist_authorization,
778
- & in_memory_torrent_repository,
779
- & db_torrent_repository,
780
- ) ;
768
+ let tracker = initialize_tracker ( & config, & in_memory_torrent_repository, & db_torrent_repository) ;
781
769
782
770
let scrape_handler = Arc :: new ( ScrapeHandler :: new ( & whitelist_authorization, & in_memory_torrent_repository) ) ;
783
771
@@ -791,19 +779,14 @@ mod tests {
791
779
let (
792
780
_database,
793
781
_in_memory_whitelist,
794
- whitelist_authorization ,
782
+ _whitelist_authorization ,
795
783
_authentication_service,
796
784
in_memory_torrent_repository,
797
785
db_torrent_repository,
798
786
torrents_manager,
799
787
) = initialize_tracker_dependencies ( & config) ;
800
788
801
- let tracker = initialize_tracker (
802
- & config,
803
- & whitelist_authorization,
804
- & in_memory_torrent_repository,
805
- & db_torrent_repository,
806
- ) ;
789
+ let tracker = initialize_tracker ( & config, & in_memory_torrent_repository, & db_torrent_repository) ;
807
790
808
791
( tracker, torrents_manager, in_memory_torrent_repository)
809
792
}
0 commit comments