~ubuntu-branches/ubuntu/trusty/ejabberd/trusty-proposed

« back to all changes in this revision

Viewing changes to src/eldap/eldap_utils.erl

  • Committer: Bazaar Package Importer
  • Author(s): Konstantin Khomoutov, Konstantin Khomoutov, Gerfried Fuchs
  • Date: 2010-04-06 13:00:03 UTC
  • mfrom: (1.1.14 upstream) (13.1.1 sid)
  • Revision ID: james.westby@ubuntu.com-20100406130003-ub626hx26kgazp79
Tags: 2.1.3-1
[ Konstantin Khomoutov ]
* New upstream release.
* Remove obsolete c2s-p1-fsm.patch
* Remove obsolete ejabberdctl-help-dashes.patch
* Update mod_admin_extra to revision 1078
* Refresh shared_roster_recent.patch
* Refresh shared_roster_online.patch
* Clarify how to do mixed IPv4/IPv6 setup of ejabberd listeners
  as suggested by Marc Dequènes in the discussion of #573801.

[ Gerfried Fuchs ]
* Remove Torsten Werner from maintainer field on his own wish - thanks for
  your work so far! (closes: #578722)
* Promote Konstantin to Maintainer to best fit reality. Enjoy. :)

Show diffs side-by-side

added added

removed removed

Lines of Context:
53
53
 
54
54
%% Not tail-recursive, but it is not very terribly.
55
55
%% It stops finding on the first not empty value.
 
56
find_ldap_attrs([{Attr} | Rest], Attributes) ->
 
57
    find_ldap_attrs([{Attr, "%u"} | Rest], Attributes);
56
58
find_ldap_attrs([{Attr, Format} | Rest], Attributes) ->
57
 
        case get_ldap_attr(Attr, Attributes) of
 
59
    case get_ldap_attr(Attr, Attributes) of
58
60
        Value when is_list(Value), Value /= "" ->
59
 
                {Value, Format};
 
61
            {Value, Format};
60
62
        _ ->
61
 
                find_ldap_attrs(Rest, Attributes)
62
 
        end;
 
63
            find_ldap_attrs(Rest, Attributes)
 
64
    end;
63
65
find_ldap_attrs([], _) ->
64
 
        "".
 
66
    "".
65
67
 
66
68
get_ldap_attr(LDAPAttr, Attributes) ->
67
69
    Res = lists:filter(