@@ -9,27 +9,21 @@ public class CachePeriodicService : BackgroundService
99 private readonly ILogger < CachePeriodicService > _logger ;
1010 private readonly CloudflareService _cloudflareService ;
1111 private readonly GithubCacheService _githubCacheService ;
12- private readonly VrChatStatusCacheService _vrChatStatusCacheService ;
1312
1413 private DateTime _githubLastRefresh = DateTime . MinValue ;
15- private DateTime _vrChatStatusLastRefresh = DateTime . MinValue ;
1614
17- public CachePeriodicService ( ILogger < CachePeriodicService > logger , CloudflareService cloudflareService , GithubCacheService githubCacheService , VrChatStatusCacheService vrChatStatusCacheService )
15+ public CachePeriodicService ( ILogger < CachePeriodicService > logger , CloudflareService cloudflareService , GithubCacheService githubCacheService )
1816 {
1917 _logger = logger ;
2018 _cloudflareService = cloudflareService ;
2119 _githubCacheService = githubCacheService ;
22- _vrChatStatusCacheService = vrChatStatusCacheService ;
2320 }
2421
2522 protected override async Task ExecuteAsync ( CancellationToken stoppingToken )
2623 {
2724 await _githubCacheService . RefreshAsync ( ) ;
2825 _githubLastRefresh = DateTime . Now ;
2926
30- await _vrChatStatusCacheService . RefreshAsync ( ) ;
31- _vrChatStatusLastRefresh = DateTime . Now ;
32-
3327 await _cloudflareService . PurgeCache ( ) ;
3428 TriggerGC ( ) ;
3529
@@ -48,17 +42,6 @@ protected override async Task ExecuteAsync(CancellationToken stoppingToken)
4842 _githubLastRefresh = DateTime . Now ;
4943 }
5044
51- if ( DateTime . Now - _vrChatStatusLastRefresh > TimeSpan . FromSeconds ( VrChatStatusRefreshInterval ) )
52- {
53- hasSomethingRefreshed |= true ;
54-
55- // We will not be caching the status.
56- // hasSomethingChanged |= await _vrChatStatusCacheService.RefreshAsync();
57- await _vrChatStatusCacheService . RefreshAsync ( ) ;
58-
59- _vrChatStatusLastRefresh = DateTime . Now ;
60- }
61-
6245 if ( hasSomethingChanged )
6346 {
6447 await _cloudflareService . PurgeCache ( ) ;
0 commit comments