Gamaliel Espinoza 8 سال پیش
والد
کامیت
6316b6f03e
1فایلهای تغییر یافته به همراه4 افزوده شده و 3 حذف شده
  1. 4 3
      tools/fourier/cli.py

+ 4 - 3
tools/fourier/cli.py

@@ -69,6 +69,7 @@ def main():
 
     stations_parser = subparsers.add_parser('station')
     stations_parser.add_argument('action')
+    stations_parser.add_argument('station', nargs='?', default='98.5')
     stations_parser.add_argument('-stations', dest='stations',
                                  type=parse_stations)
     stations_parser.add_argument('--play-only', dest='play_only',
@@ -195,10 +196,10 @@ def main():
             if args.stations:
                 stations = args.stations
                 if len(stations) < receivers_count:
-                    for i in range(receivers_count) - len(stations):
-                        receivers_count.append('98.5')
+                    for i in range(receivers_count - len(stations)):
+                        stations.append('98.5')
             else:
-                stations = ['98.5'] * receivers_count
+                stations = [args.station] * receivers_count
 
             print(stations)