mirror of
				https://github.com/ciphervance/supercell-wx.git
				synced 2025-10-31 07:30:04 +00:00 
			
		
		
		
	Remove 30 hour filter on event history
This commit is contained in:
		
							parent
							
								
									90c8c0183a
								
							
						
					
					
						commit
						e75666d7a2
					
				
					 1 changed files with 2 additions and 7 deletions
				
			
		|  | @ -190,23 +190,18 @@ void TextEventManager::Impl::HandleMessage( | ||||||
| 
 | 
 | ||||||
| void TextEventManager::Impl::Refresh() | void TextEventManager::Impl::Refresh() | ||||||
| { | { | ||||||
|    using namespace std::chrono; |  | ||||||
| 
 |  | ||||||
|    logger_->trace("Refresh"); |    logger_->trace("Refresh"); | ||||||
| 
 | 
 | ||||||
|    // Take a unique lock before refreshing
 |    // Take a unique lock before refreshing
 | ||||||
|    std::unique_lock lock(refreshMutex_); |    std::unique_lock lock(refreshMutex_); | ||||||
| 
 | 
 | ||||||
|    // Set threshold to last 30 hours
 |  | ||||||
|    auto newerThan = std::chrono::system_clock::now() - 30h; |  | ||||||
| 
 |  | ||||||
|    // Update the file listing from the warnings provider
 |    // Update the file listing from the warnings provider
 | ||||||
|    auto [newFiles, totalFiles] = warningsProvider_.ListFiles(newerThan); |    auto [newFiles, totalFiles] = warningsProvider_.ListFiles(); | ||||||
| 
 | 
 | ||||||
|    if (newFiles > 0) |    if (newFiles > 0) | ||||||
|    { |    { | ||||||
|       // Load new files
 |       // Load new files
 | ||||||
|       auto updatedFiles = warningsProvider_.LoadUpdatedFiles(newerThan); |       auto updatedFiles = warningsProvider_.LoadUpdatedFiles(); | ||||||
| 
 | 
 | ||||||
|       // Handle messages
 |       // Handle messages
 | ||||||
|       for (auto& file : updatedFiles) |       for (auto& file : updatedFiles) | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Dan Paulat
						Dan Paulat