Software /
code /
prosody
Changeset
6625:bae327ea487a
Merge 0.10->trunk
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Sun, 05 Apr 2015 16:24:10 +0200 |
parents | 6623:0da3e10b3333 (current diff) 6624:7f9b49f2758a (diff) |
children | 6626:071611bc4f1d |
files | |
diffstat | 1 files changed, 5 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/core/rostermanager.lua Sun Apr 05 15:22:33 2015 +0200 +++ b/core/rostermanager.lua Sun Apr 05 16:24:10 2015 +0200 @@ -86,12 +86,11 @@ metadata = { broken = err or nil }; roster[false] = metadata; end - if not metadata.pending then - if roster.pending and not type(roster.pending.subscription) == "string" then - metadata.pending, roster.pending = roster.pending, nil; - else - metadata.pending = {}; - end + if roster.pending and type(roster.pending.subscription) ~= "string" then + metadata.pending = roster.pending; + roster.pending = nil; + elseif not metadata.pending then + metadata.pending = {}; end return metadata; end