Skip to content

Commit

Permalink
refactor: passing through to the new sdk
Browse files Browse the repository at this point in the history
  • Loading branch information
tombuildsstuff committed Nov 19, 2018
1 parent 5302390 commit ec3e14c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 77 deletions.
18 changes: 6 additions & 12 deletions azurerm/helpers/response/response.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,16 @@ package response

import (
"net/http"

"github.com/hashicorp/go-azure-helpers/response"
)

// TODO: deprecate and remove these
func WasConflict(resp *http.Response) bool {
return responseWasStatusCode(resp, http.StatusConflict)
return response.WasConflict(resp)
}

// TODO: deprecate and remove these
func WasNotFound(resp *http.Response) bool {
return responseWasStatusCode(resp, http.StatusNotFound)
}

func responseWasStatusCode(resp *http.Response, statusCode int) bool {
if r := resp; r != nil {
if r.StatusCode == statusCode {
return true
}
}

return false
return response.WasNotFound(resp)
}
65 changes: 0 additions & 65 deletions azurerm/helpers/response/response_test.go

This file was deleted.

0 comments on commit ec3e14c

Please sign in to comment.