Skip to content
This repository has been archived by the owner on May 27, 2021. It is now read-only.

Commit

Permalink
feat(app): Check Android with $ionicApp.getDeviceTypeByNavitor()
Browse files Browse the repository at this point in the history
Closes #13
  • Loading branch information
jskrzypek committed Jun 8, 2015
1 parent 5e5ec8b commit 4b2e781
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions ionic-deploy.js
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,7 @@ angular.module('ionic.service.deploy', ['ionic.service.core'])

return deferred.promise;
}
}
};
}])

.run(['$ionicApp', function($ionicApp) {
Expand All @@ -269,11 +269,11 @@ angular.module('ionic.service.deploy', ['ionic.service.core'])
function onDeviceReady() {
console.log("Ionic Deploy: Init");
if (typeof IonicDeploy != "undefined") {
if (ionic.Platform.isAndroid()) {
if ($ionicApp.getDeviceTypeByNavigator() === 'android') {
IonicDeploy.init($ionicApp.getApp().app_id);
} else {
IonicDeploy.redirect($ionicApp.getApp().app_id);
}
}
};
}
}]);

0 comments on commit 4b2e781

Please sign in to comment.