projects
/
prosody.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
cd3f3ff
)
mod_pep: Fixed a nil access error
author
Waqas Hussain
<waqas20@gmail.com>
Sun, 28 Jun 2009 17:23:06 +0000
(22:23 +0500)
committer
Waqas Hussain
<waqas20@gmail.com>
Sun, 28 Jun 2009 17:23:06 +0000
(22:23 +0500)
plugins/mod_pep.lua
patch
|
blob
|
history
diff --git
a/plugins/mod_pep.lua
b/plugins/mod_pep.lua
index 78098423c64fb67a25ade0b93c7aa42921f17c51..4a8300f1d0fc8600bc7021b54658ddff63b25ac6 100644
(file)
--- a/
plugins/mod_pep.lua
+++ b/
plugins/mod_pep.lua
@@
-33,8
+33,10
@@
local function publish(session, node, item)
-- store for the future
local user_data = data[bare];
if disable then
-- store for the future
local user_data = data[bare];
if disable then
- if user_data then user_data[node] = nil; end
- if not next(user_data) then data[bare] = nil; end
+ if user_data then
+ user_data[node] = nil;
+ if not next(user_data) then data[bare] = nil; end
+ end
else
if not user_data then user_data = {}; data[bare] = user_data; end
user_data[node] = stanza;
else
if not user_data then user_data = {}; data[bare] = user_data; end
user_data[node] = stanza;