Software /
code /
prosody
Changeset
11470:5ebad952ebf7
util.datamapper: Fix to skip parsing wrapped arrays that aren't there
Turns out the unreachable error is reachable :D
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Mon, 22 Mar 2021 10:03:32 +0100 |
parents | 11469:087d710ed520 |
children | 11471:ab03de8e503e |
files | teal-src/util/datamapper.tl util/datamapper.lua |
diffstat | 2 files changed, 0 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/teal-src/util/datamapper.tl Sun Mar 21 02:26:28 2021 +0100 +++ b/teal-src/util/datamapper.tl Mon Mar 22 10:03:32 2021 +0100 @@ -175,8 +175,6 @@ local wrapper = s:get_child(name, namespace); if wrapper then out[prop] = parse_array(propschema, wrapper); - else - error "unreachable" end else local value : string = extract_value (s, value_where, proptype, name, namespace, prefix, single_attribute, enums)
--- a/util/datamapper.lua Sun Mar 21 02:26:28 2021 +0100 +++ b/util/datamapper.lua Mon Mar 22 10:03:32 2021 +0100 @@ -143,8 +143,6 @@ local wrapper = s:get_child(name, namespace); if wrapper then out[prop] = parse_array(propschema, wrapper); - else - error("unreachable") end else local value = extract_value(s, value_where, proptype, name, namespace, prefix, single_attribute, enums)