mirror of https://github.com/hashicorp/terraform
parent
a1f7789161
commit
fd2fcaf1d5
@ -0,0 +1,21 @@
|
||||
package resource
|
||||
|
||||
type NotFoundError struct {
|
||||
LastError error
|
||||
LastRequest interface{}
|
||||
LastResponse interface{}
|
||||
Message string
|
||||
Retries int
|
||||
}
|
||||
|
||||
func (e *NotFoundError) Error() string {
|
||||
if e.Message != "" {
|
||||
return e.Message
|
||||
}
|
||||
|
||||
return "couldn't find resource"
|
||||
}
|
||||
|
||||
func NewNotFoundError(err string) *NotFoundError {
|
||||
return &NotFoundError{Message: err}
|
||||
}
|
||||
Loading…
Reference in new issue