Quit on promise rejections.
This commit is contained in:
parent
e5dc170ca5
commit
ea0bb782dc
@ -502,6 +502,7 @@
|
||||
(let [start-time (current-time)]
|
||||
;; If --config-path is specified, definitely try to read that
|
||||
;; file. Otherwise, only read config.yaml if it exists.
|
||||
(p/try
|
||||
(p/let [base-config (if-let [config-path (.-config commander)]
|
||||
(util/read-config config-path)
|
||||
(if (fs/existsSync default-config-path)
|
||||
@ -532,7 +533,10 @@
|
||||
"Completed processing in %f seconds: tracking %s aircraft; %s potential circles"
|
||||
(/ (- end-time start-time) 1000)
|
||||
(count new-db)
|
||||
(count potential-circles)))))))
|
||||
(count potential-circles)))))
|
||||
(p/catch :default e
|
||||
(log-error "%s" (.-stack e))
|
||||
(.exit js/process 1)))))
|
||||
|
||||
|
||||
;; (.on js/process "unhandledRejection"
|
||||
|
Loading…
Reference in New Issue
Block a user