From 2a88f14b440f99af13d6e2085b37a390737cc83c Mon Sep 17 00:00:00 2001 From: bootstraponline Date: Mon, 18 Nov 2013 19:36:47 -0500 Subject: [PATCH] Check for start err --- lib/appium.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/appium.js b/lib/appium.js index 312cf9c5c..6e4ce15cc 100644 --- a/lib/appium.js +++ b/lib/appium.js @@ -715,7 +715,8 @@ Appium.prototype.reset = function(cb) { this.resetting = true; this.stop(function() { logger.info("Restarting app"); - this.start(this.oldDesiredCapabilities, function() { + this.start(this.oldDesiredCapabilities, function(err) { + if (err) return cb(err); this.resetting = false; this.device.implicitWaitMs = oldImpWait; this.sessionId = oldId;