-{$wait} = require '../fibers-utils'
+$debug = (require 'debug') 'xo:api:vm'
+{$coroutine, $wait} = require '../fibers-utils'
 
 #=====================================================================
 

  catch
    @throw 'NO_SUCH_OBJECT'

  {sessionId} = @getXAPI pool
  host = @getObject pool.master, 'host'

  url = $wait @registerProxyRequest {
    # Receive a POST but send a PUT.

    hostname: host.address
    pathname: '/pool_patch_upload'
    query: {
      session_id: xapi.sessionId
      task_id: taskRef
    }
  }

