[Mobile] Browse Controller

Adjusted BrowseController to hide the
back button if current object represented/
selected has no context.
This commit is contained in:
Shivam Dave 2015-08-26 20:20:16 -07:00
parent 6e172359b4
commit a0169ad158

View File

@ -150,9 +150,15 @@ define(
}
function checkRoot() {
var parent = navigationService.getNavigation().getCapability('context').getParent();
if (parent.getId() !== ROOT_ID) {
$scope.atRoot = false;
var context = navigationService.getNavigation().getCapability('context'),
parent;
if (context) {
parent = context.getParent();
if (parent.getId() !== ROOT_ID) {
$scope.atRoot = false;
} else {
$scope.atRoot = true;
}
} else {
$scope.atRoot = true;
}