Skip to content

Commit

Permalink
do not fetch stat if the VM has current operations
Browse files Browse the repository at this point in the history
  • Loading branch information
olivierlambert committed Apr 20, 2015
1 parent e09988e commit a5c9880
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/modules/vm/index.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ module.exports = angular.module 'xoWebApp.vm', [
return this._trig(t2)

.catch (err) =>
if !this.running || $scope.VM.power_state isnt 'Running'
if !this.running || $scope.VM.power_state isnt 'Running' || $scope.isVMWorking($scope.VM)
this.stop()
else
this._next()
Expand Down Expand Up @@ -131,7 +131,7 @@ module.exports = angular.module 'xoWebApp.vm', [

prepareDiskData mountedIso

if VM.power_state is 'Running'
if VM.power_state is 'Running' && !($scope.isVMWorking($scope.VM))
refreshStatControl.start()
else
refreshStatControl.stop()
Expand Down

0 comments on commit a5c9880

Please sign in to comment.