projects
/
prosody.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
114d526
)
util.stanza: Optimisation, remove useless if...then in stanza:children() iterator
author
Matthew Wild
<mwild1@gmail.com>
Sun, 29 Aug 2010 14:07:00 +0000
(15:07 +0100)
committer
Matthew Wild
<mwild1@gmail.com>
Sun, 29 Aug 2010 14:07:00 +0000
(15:07 +0100)
util/stanza.lua
patch
|
blob
|
history
diff --git
a/util/stanza.lua
b/util/stanza.lua
index e787cacfe21fedcc6753d0a70ae3531e9e0853b5..3ab4bb42f8cad52daf20b5da27a74df938f73225 100644
(file)
--- a/
util/stanza.lua
+++ b/
util/stanza.lua
@@
-122,8
+122,7
@@
function stanza_mt:children()
local i = 0;
return function (a)
i = i + 1
- local v = a[i]
- if v then return v; end
+ return a[i];
end, self, i;
end