mirror of
https://github.com/fosrl/pangolin.git
synced 2026-02-22 21:06:37 +00:00
Add increment options and slight cleanup
This commit is contained in:
@@ -170,18 +170,18 @@ export const handleOlmPingMessage: MessageHandler = async (context) => {
|
||||
lastPing: Math.floor(Date.now() / 1000),
|
||||
online: true
|
||||
})
|
||||
.where(eq(clients.clientId, olm.clientId)).returning();
|
||||
|
||||
.where(eq(clients.clientId, olm.clientId))
|
||||
.returning();
|
||||
|
||||
// get the version
|
||||
const configVersion = await getClientConfigVersion(olm.olmId);
|
||||
|
||||
if (message.configVersion && configVersion != message.configVersion) {
|
||||
logger.warn(`Olm ping with outdated config version: ${message.configVersion} (current: ${configVersion})`);
|
||||
logger.warn(
|
||||
`Olm ping with outdated config version: ${message.configVersion} (current: ${configVersion})`
|
||||
);
|
||||
await sendOlmSyncMessage(olm, client);
|
||||
}
|
||||
|
||||
|
||||
} catch (error) {
|
||||
logger.error("Error handling ping message", { error });
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user