Skip to content

Commit

Permalink
Removed delete function
Browse files Browse the repository at this point in the history
  • Loading branch information
AdminTurnedDevOps committed Sep 17, 2020
1 parent 8e5d56a commit d4cf6b8
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 30 deletions.
15 changes: 0 additions & 15 deletions octopusdeploy/resource_azure_service_principal.go
Expand Up @@ -188,18 +188,3 @@ func resourceAzureServicePrincipalUpdate(d *schema.ResourceData, m interface{})
d.SetId(updatedAccount.ID)
return nil
}

func resourceAzureServicePrincipalDelete(d *schema.ResourceData, m interface{}) error {
apiClient := m.(*client.Client)

accountID := d.Id()

err := apiClient.Accounts.Delete(accountID)

if err != nil {
return fmt.Errorf("error deleting azure service principal id %s: %s", accountID, err.Error())
}

d.SetId("")
return nil
}
15 changes: 0 additions & 15 deletions octopusdeploy/resource_usernamepassword_account.go
Expand Up @@ -118,18 +118,3 @@ func resourceUsernamePasswordUpdate(d *schema.ResourceData, m interface{}) error
d.SetId(updatedAccount.ID)
return nil
}

func resourceUsernamePasswordDelete(d *schema.ResourceData, m interface{}) error {
apiClient := m.(*client.Client)

accountID := d.Id()

err := apiClient.Accounts.Delete(accountID)

if err != nil {
return fmt.Errorf("error deleting username password account id %s: %s", accountID, err.Error())
}

d.SetId("")
return nil
}

0 comments on commit d4cf6b8

Please sign in to comment.