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 2016/04/07 18:28:00 UTC

[whimsy] branch master updated: Status now uses symbols, not strings

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

sebb pushed a commit to branch master
in repository https://git-dual.apache.org/repos/asf/whimsy.git

The following commit(s) were added to refs/heads/master by this push:
       new  0606ad9   Status now uses symbols, not strings
       new  1d7ea47   Merge branch 'master' of https://github.com/apache/whimsy
0606ad9 is described below

commit 0606ad9ee6c90fb1312f3648de279f287950d0a2
Author: Sebb <se...@apache.org>
AuthorDate: Thu Apr 7 17:26:51 2016 +0100

    Status now uses symbols, not strings
---
 www/status/index.cgi | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/www/status/index.cgi b/www/status/index.cgi
index baf5af3..0bec5c4 100755
--- a/www/status/index.cgi
+++ b/www/status/index.cgi
@@ -9,7 +9,7 @@ git_info = `git show --format="%h  %ci"  -s HEAD`.strip rescue "?"
 git_repo = `git ls-remote origin master`.strip rescue "?"
 
 # Get new status every minute
-if not status['mtime'] or Time.now - Time.parse(status['mtime']) > 60
+if not status[:mtime] or Time.now - Time.parse(status[:mtime]) > 60
   begin
     require_relative './monitor'
     status = Monitor.new.status || {}
@@ -24,10 +24,10 @@ if not status['mtime'] or Time.now - Time.parse(status['mtime']) > 60
 end
 
 # The following is what infrastructure team sees:
-if %w(success info).include? status['level']
+if %w(success info).include? status[:level]
   print "Status: 200 OK\r\n\r\n"
 else
-  print "Status: 400 #{status['title'] || 'failure'}\r\n\r\n"
+  print "Status: 400 #{status[:title] || 'failure'}\r\n\r\n"
 end
 
 # What the browser sees:

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