Software /
code /
prosody-modules
Diff
mod_storage_xmlarchive/mod_storage_xmlarchive.lua @ 2514:d47a7e6e9adc
mod_storage_xmlarchive: Raise error instead of warning if there's ever more than one stanza in a chunk (this indicates some kind of corruption)
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Mon, 20 Feb 2017 01:47:44 +0100 |
parent | 2420:309db11494c2 |
child | 2595:307ddebb72e1 |
line wrap: on
line diff
--- a/mod_storage_xmlarchive/mod_storage_xmlarchive.lua Mon Feb 20 00:09:45 2017 +0100 +++ b/mod_storage_xmlarchive/mod_storage_xmlarchive.lua Mon Feb 20 01:47:44 2017 +0100 @@ -83,9 +83,7 @@ local result; local function cb(_, stanza) - if result then - module:log("warn", "Multiple items in chunk"); - end + assert(not result, "Multiple items in chunk"); result = stanza; end