Handle memory limit errors
This commit is contained in:
@@ -501,6 +501,11 @@ angular.module('Application').controller('AppController', ['$scope', '$location'
|
||||
|
||||
var memoryLimit = $scope.resources.memoryLimit === $scope.resources.memoryTicks[0] ? 0 : $scope.resources.memoryLimit;
|
||||
Client.configureApp($scope.app.id, 'memory_limit', { memoryLimit: memoryLimit }, function (error) {
|
||||
if (error && error.statusCode === 400) {
|
||||
$scope.resources.busy = false;
|
||||
$scope.resources.error.memoryLimit = true;
|
||||
return;
|
||||
}
|
||||
if (error) return Client.error(error);
|
||||
|
||||
$scope.resources.currentMemoryLimit = $scope.resources.memoryLimit;
|
||||
|
||||
Reference in New Issue
Block a user