Mercurial > prosody-modules
comparison mod_auth_ldap/mod_auth_ldap.lua @ 3188:5c3f3f5a4377
Backed out parts of changeset a81456a13797
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Wed, 18 Jul 2018 15:57:13 +0200 |
parents | a81456a13797 |
children | 3af2da030397 |
comparison
equal
deleted
inserted
replaced
3187:7c450c27d4ba | 3188:5c3f3f5a4377 |
---|---|
33 | 33 |
34 -- luacheck: ignore 411/success | 34 -- luacheck: ignore 411/success |
35 local success, iterator, invariant, initial = pcall(ld[method], ld, ...); | 35 local success, iterator, invariant, initial = pcall(ld[method], ld, ...); |
36 if not success then ld = nil; return nil, iterator, "search"; end | 36 if not success then ld = nil; return nil, iterator, "search"; end |
37 | 37 |
38 module:log("debug", "success = %s, invariant = %s", | |
39 tostring(success), | |
40 tostring(invariant)); | |
41 | |
42 local success, dn, attr = pcall(iterator, invariant, initial); | 38 local success, dn, attr = pcall(iterator, invariant, initial); |
43 module:log("debug", "success = %s, dn = %s, attr = %s", | |
44 tostring(success), | |
45 tostring(dn), | |
46 tostring(attr)); | |
47 if not success then ld = nil; return success, dn, "iter"; end | 39 if not success then ld = nil; return success, dn, "iter"; end |
48 | |
49 | 40 |
50 return dn, attr, "return"; | 41 return dn, attr, "return"; |
51 end | 42 end |
52 | 43 |
53 function ldap_do(method, retry_count, ...) | 44 function ldap_do(method, retry_count, ...) |