Skip to content

use operation.promise() instead of after-operation #6

Description

@DrPaulBrewer

Probably should now use operation.promise() instead of after-operation

Example: Deleting a VM in Google Compute Engine

// other code in function to identify zone, name of vm to delete
return gce.zone(zone).vm(name).delete().then(
      ([op, apiResponse]) => (op.promise()),
      (e)=>(console.log('error on delete vm '+name+':'+e))
    );

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions