whimsical-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ru...@apache.org
Subject [whimsy] branch master updated: support foundation lists too
Date Mon, 17 Apr 2017 13:55:40 GMT
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

The following commit(s) were added to refs/heads/master by this push:
       new  3d8a5e2   support foundation lists too
3d8a5e2 is described below

commit 3d8a5e2fa11ecb82832e21df31eeb8f9a51f42da
Author: Sam Ruby <rubys@intertwingly.net>
AuthorDate: Mon Apr 17 09:55:28 2017 -0400

    support foundation lists too
---
 www/roster/models/committee.rb | 2 +-
 www/roster/models/committer.rb | 2 +-
 www/roster/models/ppmc.rb      | 3 ++-
 3 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/www/roster/models/committee.rb b/www/roster/models/committee.rb
index 110a011..2d20092 100644
--- a/www/roster/models/committee.rb
+++ b/www/roster/models/committee.rb
@@ -20,7 +20,7 @@ class Committee
          mail_list = "#{pmc.mail_list}.apache.org"
          moderators = File.read(LIST_MODS).split(/\n\n/).map do |stanza|
            list = stanza.match(/(\w+\.apache\.org)\/(.*?)\//)
-           next unless list[1] == mail_list
+           next unless list and list[1] == mail_list
  
            ["#{list[2]}@#{list[1]}", stanza.scan(/^(.*@.*)/).flatten.sort]
         end
diff --git a/www/roster/models/committer.rb b/www/roster/models/committer.rb
index 215eed2..1ce3d22 100644
--- a/www/roster/models/committer.rb
+++ b/www/roster/models/committer.rb
@@ -123,7 +123,7 @@ class Committer
 
       if File.exist? LIST_MODS
         moderators = File.read(LIST_MODS).split(/\n\n/).map do |stanza|
-          list = stanza.match(/(\w+\.apache\.org)\/(.*?)\//)
+          list = stanza.match(/(\w*\.?apache\.org)\/(.*?)\//)
 
           ["#{list[2]}@#{list[1]}", stanza.scan(/^(.*@.*)/).flatten]
         end
diff --git a/www/roster/models/ppmc.rb b/www/roster/models/ppmc.rb
index fa8432d..5c056d0 100644
--- a/www/roster/models/ppmc.rb
+++ b/www/roster/models/ppmc.rb
@@ -14,7 +14,8 @@ class PPMC
          mail_list = ppmc.mail_list
          moderators = File.read(LIST_MODS).split(/\n\n/).map do |stanza|
            list = stanza.match(/(\w+)\.apache\.org\/(.*?)\//)
-           next unless list[1] == mail_list or list[2] =~ /^#{mail_list}-/
+           next unless list and 
+             (list[1] == mail_list or list[2] =~ /^#{mail_list}-/)
  
            ["#{list[2]}@#{list[1]}.apache.org", 
              stanza.scan(/^(.*@.*)/).flatten.sort]

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

Mime
View raw message