You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@whimsical.apache.org by se...@apache.org on 2020/07/16 15:13:14 UTC

[whimsy] branch master updated: Simplify; allow for missing epoch

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 8e58bb5  Simplify; allow for missing epoch
8e58bb5 is described below

commit 8e58bb58b705abbf2ae03b92823642f88980c0bf
Author: Sebb <se...@apache.org>
AuthorDate: Thu Jul 16 16:13:05 2020 +0100

    Simplify; allow for missing epoch
---
 www/roster/models/committer.rb | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/www/roster/models/committer.rb b/www/roster/models/committer.rb
index 0afb1fd..db4ab32 100644
--- a/www/roster/models/committer.rb
+++ b/www/roster/models/committer.rb
@@ -151,24 +151,26 @@ class Committer
 
         file = ASF::EmeritusFiles.find(person)
         if file
-          response[:forms][:emeritus] = ASF::SVN.svnpath!('emeritus', file)
+          response[:forms][:emeritus] = ASF::EmeritusFiles.svnpath!(file)
         end
 
         epoch, file = ASF::EmeritusRequestFiles.find(person, true)
         if file
-          response[:forms][:emeritus_request] = ASF::SVN.svnpath!('emeritus-requests-received', file)
+          response[:forms][:emeritus_request] = ASF::EmeritusRequestFiles.svnpath!(file)
           # Calculate the age in days
           response[:emeritus_request_age] = (((Time.now.to_i - epoch.to_i).to_f/SECS_TO_DAYS)).round(1).to_s
+        elsif epoch # listing does not have both epoch and file
+          response[:forms][:emeritus_request] = ASF::EmeritusRequestFiles.svnpath!(epoch)
         end
 
         file = ASF::EmeritusRescindedFiles.find(person)
         if file
-          response[:forms][:emeritus_rescinded] = ASF::SVN.svnpath!('emeritus-requests-rescinded', file)
+          response[:forms][:emeritus_rescinded] = ASF::EmeritusRescindedFiles.svnpath!(file)
         end
 
         file = ASF::EmeritusReinstatedFiles.find(person)
         if file
-          response[:forms][:emeritus_reinstated] = ASF::SVN.svnpath!('emeritus-reinstated', file)
+          response[:forms][:emeritus_reinstated] = ASF::EmeritusReinstatedFiles.svnpath!(file)
         end
 
       else