diff --git a/lib/devices-service.js b/lib/devices-service.js
index <HASH>..<HASH> 100644
--- a/lib/devices-service.js
+++ b/lib/devices-service.js
@@ -11,18 +11,18 @@
 
 	function hasDevices(platform) {
 		var platformsServices = getPlatformServices(platform);
-		return Q.fcall(hasDevicesOfPlatforms, _.toArray(platformsServices));
+		return Q.fcall(hasDevicesOfPlatforms, _.toArray(platformsServices), 0);
 	}
 
-	function hasDevicesOfPlatforms(platformsServicesArray) {
-		if (platformsServicesArray.length > 0) {
-			var platformsService = platformsServicesArray[0];
+	function hasDevicesOfPlatforms(platformsServicesArray, startIndex) {
+		if (platformsServicesArray.length - startIndex > 0) {
+			var platformsService = platformsServicesArray[startIndex];
 			return platformsService.hasDevices()
 				.then(function(result) {
 					if (result) {
 						return true;
 					} else {
-						hasDevicesOfPlatforms(platformsServicesArray.slice(1));
+						hasDevicesOfPlatforms(platformsServicesArray, startIndex + 1);
 					}
 				});
 		} else {
Optimize the "hasDevices" method to run in O(n) instead of O(n*n)