File tree Expand file tree Collapse file tree 3 files changed +12
-16
lines changed
Expand file tree Collapse file tree 3 files changed +12
-16
lines changed Original file line number Diff line number Diff line change @@ -13,9 +13,7 @@ function ControllerInstance(
1313 $rootScope ,
1414 $scope ,
1515 $state ,
16- $log ,
1716 $stateParams ,
18- exists ,
1917 fetchUser
2018) {
2119 var dataInstance = $scope . dataInstance = {
@@ -59,7 +57,15 @@ function ControllerInstance(
5957 async . waterfall ( [
6058 fetchUser ,
6159 fetchInstance
62- ] ) ;
60+ ] , function ( err ) {
61+ if ( err ) {
62+ $state . go ( 'instance.instance' , {
63+ instanceName : '' ,
64+ userName : $stateParams . userName
65+ } , { reload : true } ) ;
66+ }
67+ errs . handler ( err ) ;
68+ } ) ;
6369 }
6470 // watch showExplorer (toggle when user clicks file menu)
6571 // if no running container, return early (user shouldn't be able to even click
Original file line number Diff line number Diff line change @@ -10,8 +10,7 @@ function ControllerNew(
1010 fetchUser ,
1111 $scope ,
1212 $state ,
13- uuid ,
14- $stateParams
13+ uuid
1514) {
1615
1716 var thisUser ;
Original file line number Diff line number Diff line change @@ -6,16 +6,10 @@ require('app')
66 * the active account
77 * @ngInject
88 */
9- function instanceList (
10- async ,
11- determineActiveAccount ,
9+ function instanceList (
1210 getInstanceClasses ,
1311 getInstanceAltTitle ,
14- QueryAssist ,
15- fetchUser ,
16- $rootScope ,
17- $state ,
18- user
12+ $state
1913) {
2014 return {
2115 restrict : 'E' ,
@@ -26,9 +20,6 @@ function instanceList (
2620 state : '='
2721 } ,
2822 link : function ( $scope , elem , attrs ) {
29- // The sidebar should only update if the given instance list changes, which can happen in two
30- // ways. The activeAccount changed and we fetched them, or the collection changed in the
31- // api-client because an instance was modified/created/removed. Because of how the api-client
3223
3324 $scope . stateToInstance = function ( instance ) {
3425 $state . go ( 'instance.instance' , {
You can’t perform that action at this time.
0 commit comments