# HG changeset patch # User Kim Alvefur # Date 1586705416 -7200 # Node ID d229e4d315986866c967cf2c32b19df7954f480f # Parent 05e4645fc9b3c3a7d3afe5b66b0bacf7e796d98d mod_scansion_record: Indent stanzas in recordings Improves readability, easier to see structure. diff -r 05e4645fc9b3 -r d229e4d31598 plugins/mod_scansion_record.lua --- a/plugins/mod_scansion_record.lua Sun Apr 12 17:03:05 2020 +0200 +++ b/plugins/mod_scansion_record.lua Sun Apr 12 17:30:16 2020 +0200 @@ -37,8 +37,7 @@ end local function record_stanza(stanza, session, verb) - local flattened = tostring(stanza):gsub("><", ">\n\t<"); - -- TODO Proper prettyprinting with indentation + local flattened = tostring(stanza:indent(2, "\t")); record(session.scansion_id.." "..verb..":\n\t"..flattened.."\n\n"); end