You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@whimsical.apache.org by ru...@apache.org on 2017/07/12 23:01:11 UTC

[whimsy] 01/02: reduce LDAP to a simple list

This is an automated email from the ASF dual-hosted git repository.

rubys pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/whimsy.git

commit 04671a191f83c9861d74928b53b2aa993926e64a
Author: Sam Ruby <ru...@intertwingly.net>
AuthorDate: Wed Jul 12 18:49:15 2017 -0400

    reduce LDAP to a simple list
---
 www/roster/models/committee.rb        | 2 +-
 www/roster/views/pmc/committers.js.rb | 2 +-
 www/roster/views/pmc/pmc.js.rb        | 6 +++---
 3 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/www/roster/models/committee.rb b/www/roster/models/committee.rb
index 3a59c12..d85e5fe 100644
--- a/www/roster/models/committee.rb
+++ b/www/roster/models/committee.rb
@@ -53,7 +53,7 @@ class Committee
       report: pmc.report,
       site: pmc.site,
       established: pmc.established,
-      ldap: Hash[members.map {|person| [person.id, person.cn]}],
+      ldap: members.map(&:id),
       members: pmc.roster.keys,
       committers: Hash[committers.map {|person| [person.id, person.cn]}],
       asfmembers: (ASF.members & people).map(&:id),
diff --git a/www/roster/views/pmc/committers.js.rb b/www/roster/views/pmc/committers.js.rb
index d073915..16b28d8 100644
--- a/www/roster/views/pmc/committers.js.rb
+++ b/www/roster/views/pmc/committers.js.rb
@@ -27,7 +27,7 @@ class PMCCommitters < React
         _tbody do
           @committers.each do |person|
             next if @@committee.members.include? person.id
-            next if @@committee.ldap[person.id]
+            next if @@committee.ldap.include? person.id
             _PMCCommitter auth: @@auth, person: person, committee: @@committee
           end
 
diff --git a/www/roster/views/pmc/pmc.js.rb b/www/roster/views/pmc/pmc.js.rb
index 8e2edf0..7b01f2c 100644
--- a/www/roster/views/pmc/pmc.js.rb
+++ b/www/roster/views/pmc/pmc.js.rb
@@ -49,7 +49,7 @@ class PMCMembers < React
     roster = []
     
     for id in @@committee.roster
-      if @@committee.members.include?(id) or @@committee.ldap[id]
+      if @@committee.members.include?(id) or @@committee.ldap.include?(id)
         person = @@committee.roster[id]
         person.id = id
         roster << person
@@ -113,7 +113,7 @@ class PMCMember < React
 
   
             committers = @@committee.committers.keys()
-            pmc = @@committee.ldap.keys()
+            pmc = @@committee.members
             if committers.all? {|person| pmc.include? person}
                _button.btn.btn_warning 'Add as a committer only',
                  data_action: 'add commit',
@@ -136,7 +136,7 @@ class PMCMember < React
                 data_confirmation: "Add to #{@@person.name} committee-info.txt"
             end
           elsif not @@person.ldap
-             # in committee-info.txt but not in ldap
+             # in committee-info.txt but not in LDAP
             _button.btn.btn_success 'Add to LDAP',
               data_action: 'add pmc', 
               data_target: '#confirm', data_toggle: 'modal',

-- 
To stop receiving notification emails like this one, please contact
"commits@whimsical.apache.org" <co...@whimsical.apache.org>.