Builtin Prosody: new settings to choose how long the room's content is archived, and if it should be archived by default.
This commit is contained in:
@ -36,6 +36,20 @@ export async function diagProsody (test: string, options: RegisterServerOptions)
|
||||
|
||||
result.messages.push(`Prosody rooms will be grouped by '${wantedConfig.roomType}'.`)
|
||||
|
||||
if (wantedConfig.logByDefault) {
|
||||
result.messages.push('By default, room content will be archived.')
|
||||
} else {
|
||||
result.messages.push('By default, room content will not be archived.')
|
||||
}
|
||||
|
||||
if ('error' in wantedConfig.logExpiration) {
|
||||
result.messages.push({
|
||||
level: 'error',
|
||||
message: 'Errors: Room logs expiration value is not valid. Using the default value.'
|
||||
})
|
||||
}
|
||||
result.messages.push(`Room content will be saved for '${wantedConfig.logExpiration.value}'`)
|
||||
|
||||
await fs.promises.access(filePath, fs.constants.R_OK) // throw an error if file does not exist.
|
||||
result.messages.push(`The prosody configuration file (${filePath}) exists`)
|
||||
const actualContent = await fs.promises.readFile(filePath, {
|
||||
|
Reference in New Issue
Block a user