From c335cbaa182d011daef793dd3e1074e2e6497526 Mon Sep 17 00:00:00 2001
From: Jacek Kowalski <Jacek@jacekk.info>
Date: Tue, 06 Dec 2016 21:20:58 +0000
Subject: [PATCH] Change "at stop" display from "<<<" to ">>>"

---
 index.js |    7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/index.js b/index.js
index 12d1c79..cdb2886 100644
--- a/index.js
+++ b/index.js
@@ -30,13 +30,14 @@
 var alert_text = document.getElementById('alert-text');
 var alert_close = document.getElementById('alert-close');
 
+var parseStatusBoarding = '>>>';
 function parseStatus(status) {
 	switch(status.status) {
 		case 'STOPPING':
-			return '<<<';
+			return parseStatusBoarding;
 		case 'PREDICTED':
 			if(status.actualRelativeTime <= 0)
-				return '<<<';
+				return parseStatusBoarding;
 			if(status.actualRelativeTime >= 60)
 				return Math.floor(status.actualRelativeTime / 60) + ' min';
 			return status.actualRelativeTime + ' s';
@@ -173,7 +174,7 @@
 			var delay = parseDelay(data.actual[i]);
 			addCellWithText(tr, delay);
 			
-			if(status == '<<<') tr.className = 'success';
+			if(status == parseStatusBoarding) tr.className = 'success';
 			else if(parseInt(delay) > 9) tr.className = 'danger';
 			else if(parseInt(delay) > 3) tr.className = 'warning';
 			times_table.appendChild(tr);

--
Gitblit v1.9.1