Remove spaces code

This commit is contained in:
Girish Ramakrishnan
2019-05-04 18:40:10 -07:00
parent e7f614cdf3
commit 34eadebe00
6 changed files with 11 additions and 39 deletions

View File

@@ -4,7 +4,7 @@
/* global $:false */
angular.module('Application').controller('AppStoreController', ['$scope', '$location', '$timeout', '$routeParams', 'Client', 'AppStore', function ($scope, $location, $timeout, $routeParams, Client, AppStore) {
Client.onReady(function () { if (!Client.getUserInfo().admin && !Client.getConfig().features.spaces) $location.path('/'); });
Client.onReady(function () { if (!Client.getUserInfo().admin) $location.path('/'); });
$scope.HOST_PORT_MIN = 1024;
$scope.HOST_PORT_MAX = 65535;
@@ -21,7 +21,6 @@ angular.module('Application').controller('AppStoreController', ['$scope', '$loca
$scope.searchString = '';
$scope.validAppstoreAccount = false;
$scope.appstoreConfig = null;
$scope.spacesSuffix = '';
$scope.unstableApps = false;
$scope.showView = function (view) {
@@ -479,12 +478,6 @@ angular.module('Application').controller('AppStoreController', ['$scope', '$loca
function fetchAppstoreConfig(callback) {
callback = callback || function (error) { if (error) console.error(error); };
// non admins cannot read appstore settings in spaces mode
if (!$scope.user.admin && $scope.config.features.spaces) {
$scope.validAppstoreAccount = true;
return callback();
}
if ($scope.user.admin && $scope.config.managed) {
$scope.validAppstoreAccount = true;
return callback();
@@ -524,8 +517,6 @@ angular.module('Application').controller('AppStoreController', ['$scope', '$loca
function init() {
$scope.ready = false;
$scope.spacesSuffix = $scope.user.username.replace(/\./g, '-');
getAppList(function (error, apps) {
if (error) {
console.error(error);