diff --git a/lib/cylon.js b/lib/cylon.js index a8c3775..65e5bd2 100644 --- a/lib/cylon.js +++ b/lib/cylon.js @@ -105,8 +105,9 @@ Cylon.config = function(key) { // // Returns nothing Cylon.halt = function halt(callback) { - // set a timeout, in case trying to shut everything down nicely doesn't work - Utils.after((1.5).seconds(), callback); + // if robots can't shut down quickly enough, forcefully self-terminate + var timeout = Config.halt_timeout || 3000 + Utils.after(timeout, callback); var fns = [];