mirror of
https://github.com/louislam/uptime-kuma.git
synced 2025-08-10 07:11:52 +08:00
Uptime calculation improvement and 1-year uptime (#2750)
This commit is contained in:
@@ -43,7 +43,9 @@ const clearOldData = async () => {
|
||||
[ parsedPeriod * -24 ]
|
||||
);
|
||||
|
||||
await R.exec("PRAGMA optimize;");
|
||||
if (Database.dbConfig.type === "sqlite") {
|
||||
await R.exec("PRAGMA optimize;");
|
||||
}
|
||||
} catch (e) {
|
||||
log.error("clearOldData", `Failed to clear old data: ${e.message}`);
|
||||
}
|
||||
|
Reference in New Issue
Block a user