Skip to content

Commit

Permalink
Fix waiting for GCE Operations
Browse files Browse the repository at this point in the history
  • Loading branch information
tkulczynski committed Mar 2, 2015
1 parent 754a2a8 commit c4e786c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions pkg/cloudprovider/gce/gce.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ limitations under the License.
package gce_cloud

import (
"errors"
"fmt"
"io"
"io/ioutil"
Expand Down Expand Up @@ -192,6 +193,9 @@ func (gce *GCECloud) waitForRegionOp(op *compute.Operation, region string) error
return err
}
}
if pollOp.Error != nil && len(pollOp.Error.Errors) > 0 {
return errors.New(pollOp.Error.Errors[0].Message)
}
return nil
}

Expand Down

0 comments on commit c4e786c

Please sign in to comment.