diff options
author | Eric Wong <normalperson@yhbt.net> | 2012-06-18 13:45:13 -0700 |
---|---|---|
committer | Eric Wong <normalperson@yhbt.net> | 2012-06-18 13:49:47 -0700 |
commit | 963a7a144a5231f07da118cfe4fef0fb210f40c6 (patch) | |
tree | 66c9f62948334543f33f7092d68087146df3a74a /lib/raindrops | |
parent | e893686157a1abb9c6943d1c42c9cbdae1b76cd4 (diff) | |
download | raindrops-963a7a144a5231f07da118cfe4fef0fb210f40c6.tar.gz |
For hosts with many listeners, it should be easier to read the index page if the results are shown in a consistent order. Requested privately via email to raindrops@bogomips.org
Diffstat (limited to 'lib/raindrops')
-rw-r--r-- | lib/raindrops/watcher.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/raindrops/watcher.rb b/lib/raindrops/watcher.rb index 869fa17..5493374 100644 --- a/lib/raindrops/watcher.rb +++ b/lib/raindrops/watcher.rb @@ -337,7 +337,9 @@ class Raindrops::Watcher "<table><tr>" \ "<th>address</th><th>active</th><th>queued</th><th>reset</th>" \ "</tr>" << - all.map do |addr,stats| + all.sort do |a,b| + a[0] <=> b[0] # sort by addr + end.map do |addr,stats| e_addr = escape addr "<tr>" \ "<td><a href='/tail/#{e_addr}.txt' " \ |