Skip to content

Commit da285ab

Browse files
author
Peter Jönsson
committed
Move wait to correct namespace
1 parent 2066761 commit da285ab

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

wait.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import (
88

99
// waitForAsyncJob simply blocks until the the asynchronous job has
1010
// executed or has timed out.
11-
func WaitForAsyncJob(jobId string, client *CloudStackClient, timeout time.Duration) error {
11+
func (c CloudStackClient) WaitForAsyncJob(jobId string, timeout time.Duration) error {
1212
done := make(chan struct{})
1313
defer close(done)
1414

@@ -19,7 +19,7 @@ func WaitForAsyncJob(jobId string, client *CloudStackClient, timeout time.Durati
1919
attempts += 1
2020

2121
log.Printf("Checking async job status... (attempt: %d)", attempts)
22-
status, err := client.QueryAsyncJobResult(jobId)
22+
status, err := c.QueryAsyncJobResult(jobId)
2323
if err != nil {
2424
result <- err
2525
return

0 commit comments

Comments
 (0)