You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -278,9 +275,6 @@ class ModuleIRCv3MetadataDB final
278
275
}
279
276
}
280
277
281
-
// Remove entries for accounts that are no longer online if they have no persisted data.
282
-
// We keep offline accounts in the DB so metadata persists across reconnects.
283
-
(void)seenaccounts;
284
278
}
285
279
286
280
if (persistchans != ChanPolicy::NONE && chanmeta)
@@ -589,18 +583,18 @@ class ModuleIRCv3MetadataDB final
589
583
}
590
584
591
585
#ifdef _WIN32
592
-
remove(dbpath.c_str());
586
+
remove(dbpath.c_str());
593
587
#endif
594
-
if (rename(newpath.c_str(), dbpath.c_str()) < 0)
595
-
{
596
-
ServerInstance->Logs.Critical(MODNAME, "Cannot replace old database \"{}\" with new database \"{}\"! {} ({})", dbpath, newpath, strerror(errno), errno);
597
-
ServerInstance->SNO.WriteToSnoMask('a', "database: cannot replace old ircv3 metadata db \"{}\" with new db \"{}\": {} ({})", dbpath, newpath, strerror(errno), errno);
588
+
if (rename(newpath.c_str(), dbpath.c_str()) < 0)
589
+
{
590
+
ServerInstance->Logs.Critical(MODNAME, "Cannot replace old database \"{}\" with new database \"{}\"! {} ({})", dbpath, newpath, strerror(errno), errno);
591
+
ServerInstance->SNO.WriteToSnoMask('a', "database: cannot replace old ircv3 metadata db \"{}\" with new db \"{}\": {} ({})", dbpath, newpath, strerror(errno), errno);
598
592
std::error_code ec;
599
593
std::filesystem::remove(newpath, ec);
600
-
returnfalse;
601
-
}
594
+
returnfalse;
595
+
}
602
596
603
-
returntrue;
597
+
returntrue;
604
598
}
605
599
606
600
public:
@@ -698,6 +692,28 @@ class ModuleIRCv3MetadataDB final
0 commit comments