mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-05 18:24:07 +00:00
HandleError include the type of the error object
This commit is contained in:
parent
d7c40cf69e
commit
f2cb23ad6a
@ -61,7 +61,7 @@ func ErrorToAPIStatus(err error) *metav1.Status {
|
|||||||
// by REST storage - these typically indicate programmer
|
// by REST storage - these typically indicate programmer
|
||||||
// error by not using pkg/api/errors, or unexpected failure
|
// error by not using pkg/api/errors, or unexpected failure
|
||||||
// cases.
|
// cases.
|
||||||
runtime.HandleError(fmt.Errorf("apiserver received an error that is not an metav1.Status: %v", err))
|
runtime.HandleError(fmt.Errorf("apiserver received an error that is not an metav1.Status: %#+v", err))
|
||||||
return &metav1.Status{
|
return &metav1.Status{
|
||||||
TypeMeta: metav1.TypeMeta{
|
TypeMeta: metav1.TypeMeta{
|
||||||
Kind: "Status",
|
Kind: "Status",
|
||||||
|
Loading…
Reference in New Issue
Block a user