skip station if terminal
authorFlorian Schweikert <kelvan@logic.at>
Fri, 7 Oct 2011 00:28:43 +0000 (02:28 +0200)
committerFlorian Schweikert <kelvan@logic.at>
Fri, 7 Oct 2011 00:28:43 +0000 (02:28 +0200)
itip

diff --git a/itip b/itip
index 54ed263..049a17d 100755 (executable)
--- a/itip
+++ b/itip
@@ -31,6 +31,9 @@ if l and l in lines:
         for station in stations[key]:
             if s:
                 if s.startswith(station[0]) or station[0].startswith(s):
+                    if station[0] == key:
+                        # skip station if destination
+                        continue
                     # FIXME
                     print '* %s\n  %s .....' % (key, station[0]), itip.get_departures(station[1])
             else: