Software /
code /
prosody-modules
Diff
mod_mam/mod_mam.lua @ 2023:98b4794b72e4
mod_mam: Include an in-memory fallback driver
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Tue, 19 Jan 2016 17:47:47 +0100 |
parent | 2022:77b9c7e5fd63 |
child | 2024:6f4dcc723a60 |
line wrap: on
line diff
--- a/mod_mam/mod_mam.lua Tue Jan 19 17:47:05 2016 +0100 +++ b/mod_mam/mod_mam.lua Tue Jan 19 17:47:47 2016 +0100 @@ -39,10 +39,8 @@ local archive = assert(module:open_store(archive_store, "archive")); if archive.name == "null" then - module:log("debug", "Attempt to open archive storage returned null driver"); - module:log("error", "Unable to open archive storage, no archive capable storage driver enabled?"); - module:log("info", "See https://prosody.im/doc/storage and https://prosody.im/doc/archiving for more information"); - return; + module:log("info", "Using in-memory fallback archive driver"); + archive = module:require "fallback_archive"; elseif not archive.find then module:log("debug", "Attempt to open archive storage returned a valid driver but it does not seem to implement the storage API"); module:log("error", "mod_%s does not support archiving", archive._provided_by or archive.name and "storage_"..archive.name.."(?)" or "<unknown>");