mirror of https://github.com/louislam/uptime-kuma
				
				
				
			Merge pull request #2961 from chakflying/feat/flush-wal
Chore: Flush WAL on shutdownpull/2867/head^2
						commit
						6356b1e50a
					
				| 
						 | 
				
			
			@ -417,6 +417,9 @@ class Database {
 | 
			
		|||
 | 
			
		||||
        log.info("db", "Closing the database");
 | 
			
		||||
 | 
			
		||||
        // Flush WAL to main database
 | 
			
		||||
        await R.exec("PRAGMA wal_checkpoint(TRUNCATE)");
 | 
			
		||||
 | 
			
		||||
        while (true) {
 | 
			
		||||
            Database.noReject = true;
 | 
			
		||||
            await R.close();
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue