This is an automated email from the ASF dual-hosted git repository.
sebb 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 f1a15331 Grab statuses once
f1a15331 is described below
commit f1a15331f3817cc9a80d20744e9820724503e358
Author: Sebb <[email protected]>
AuthorDate: Thu Feb 9 00:27:45 2023 +0000
Grab statuses once
---
www/board/subscriptions.cgi | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
diff --git a/www/board/subscriptions.cgi b/www/board/subscriptions.cgi
index 89f765f4..e3c30064 100755
--- a/www/board/subscriptions.cgi
+++ b/www/board/subscriptions.cgi
@@ -10,6 +10,7 @@ require 'whimsy/asf/mlist'
info_chairs = ASF::Committee.load_committee_info.group_by(&:chair)
ldap_chairs = ASF.pmc_chairs
subscribers, modtime = ASF::MLIST.board_subscribers(false) # excluding
archivers
+member_statuses = ASF::Member.member_statuses
_html do
_body? do
@@ -88,10 +89,11 @@ _html do
ids.sort.each do |id, person, email|
_tr_ do
href = "/roster/committer/#{id}"
- if person.asf_member?
- if person.asf_member? == true
+ status = member_statuses[person.name]
+ if status
+ if status == :current
_td! {_strong {_a id, href: href}}
- else
+ else # emeritus or deceased
_td! {_em {_a id, href: href}}
end
elsif id.include? '*'
@@ -121,7 +123,7 @@ _html do
else
_td.text_danger text
end
- elsif person.asf_member?
+ elsif member_statuses[person.name]
_td
elsif ldap_chairs.include? person
_td.text_danger '***LDAP only***'
@@ -152,8 +154,10 @@ _html do
person = ASF::Person.find(id)
_tr_ do
href = "/roster/committer/#{id}"
- if person.asf_member?
+ if member_statuses[person.name] == :current
_td! {_strong {_a id, href: href}}
+ elsif member_statuses[person.name] # emeritus or deceased
+ _td! {_em {_a id, href: href}}
else
_td {_a id, href: href}
end