Fixed session key rotation problem with a default empty array on null value. (#5896)

pull/5897/head
SamTV12345 2023-08-29 18:00:14 +02:00 committed by GitHub
parent 3f6ba064d8
commit efdf9dbe36
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -160,7 +160,7 @@ class SecretRotator {
// TODO: This is racy. If two instances start up at the same time and there are no existing // TODO: This is racy. If two instances start up at the same time and there are no existing
// matching publications, each will generate and publish their own paramters. In practice this // matching publications, each will generate and publish their own paramters. In practice this
// is unlikely to happen, and if it does it can be fixed by restarting both Etherpad instances. // is unlikely to happen, and if it does it can be fixed by restarting both Etherpad instances.
const dbKeys = await db.findKeys(`${this._dbPrefix}:*`, null); const dbKeys = await db.findKeys(`${this._dbPrefix}:*`, null) || [];
let currentParams = null; let currentParams = null;
let currentId = null; let currentId = null;
const dbWrites = []; const dbWrites = [];