custom trigger: rewrite / subdir to empty string

This commit is contained in:
Jimmy Zelinskie 2015-04-01 14:12:20 -04:00
parent f55c478a30
commit 818b76d825

View file

@ -35,6 +35,11 @@ angular.module('quay').directive('triggerSetupCustom', function() {
}); });
$scope.$watch('state.subdir', function(subdir) { $scope.$watch('state.subdir', function(subdir) {
// Code elsewhere assumes root is empty string.
if (subdir === '/') {
subdir = '';
}
$scope.trigger['config']['subdir'] = subdir; $scope.trigger['config']['subdir'] = subdir;
$scope.trigger.$ready = subdir != null; $scope.trigger.$ready = subdir != null;
}); });