Edit cleaner so that the messages work better.
This commit is contained in:
		
							parent
							
								
									64f5b516fb
								
							
						
					
					
						commit
						0700d66d70
					
				
							
								
								
									
										3
									
								
								run.py
								
								
								
								
							
							
						
						
									
										3
									
								
								run.py
								
								
								
								
							| 
						 | 
				
			
			@ -30,8 +30,6 @@ log.setLevel(logging.ERROR)
 | 
			
		|||
 | 
			
		||||
 | 
			
		||||
def cleaner_thread():
 | 
			
		||||
  print_log('Notice', 'Cleaner started')
 | 
			
		||||
 | 
			
		||||
  # Call itself again after the interval
 | 
			
		||||
  cleaner = Timer(config["CLEAN_INTERVAL"], cleaner_thread)
 | 
			
		||||
  cleaner.daemon = True # Daemons will attempt to exit cleanly along with the main process, which we want
 | 
			
		||||
| 
						 | 
				
			
			@ -42,6 +40,7 @@ def cleaner_thread():
 | 
			
		|||
 | 
			
		||||
 | 
			
		||||
def delete_old():
 | 
			
		||||
  print_log('Notice', 'Cleaner running')
 | 
			
		||||
  targetTime = time.time() - config["TIME"]
 | 
			
		||||
  old = db.get_old_files(targetTime)
 | 
			
		||||
  for file in old:
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue