mirror of
https://github.com/bjc/prosody.git
synced 2025-04-07 07:07:38 +03:00
mod_storage_internal,_sql: Expose archive capabilities feature set
This was planned to be added long ago but was forgotten.
This commit is contained in:
parent
d7761bd914
commit
0028ea46e2
2 changed files with 8 additions and 0 deletions
|
@ -47,6 +47,12 @@ end
|
||||||
local archive = {};
|
local archive = {};
|
||||||
driver.archive = { __index = archive };
|
driver.archive = { __index = archive };
|
||||||
|
|
||||||
|
archive.caps = {
|
||||||
|
total = true;
|
||||||
|
quota = archive_item_limit;
|
||||||
|
truncate = true;
|
||||||
|
};
|
||||||
|
|
||||||
function archive:append(username, key, value, when, with)
|
function archive:append(username, key, value, when, with)
|
||||||
when = when or now();
|
when = when or now();
|
||||||
if not st.is_stanza(value) then
|
if not st.is_stanza(value) then
|
||||||
|
|
|
@ -232,6 +232,8 @@ end
|
||||||
local archive_store = {}
|
local archive_store = {}
|
||||||
archive_store.caps = {
|
archive_store.caps = {
|
||||||
total = true;
|
total = true;
|
||||||
|
quota = archive_item_limit;
|
||||||
|
truncate = true;
|
||||||
};
|
};
|
||||||
archive_store.__index = archive_store
|
archive_store.__index = archive_store
|
||||||
function archive_store:append(username, key, value, when, with)
|
function archive_store:append(username, key, value, when, with)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue