mirror of
				https://github.com/k3s-io/kubernetes.git
				synced 2025-10-31 05:40:42 +00:00 
			
		
		
		
	Fix CRD validation error for 'items' field
Signed-off-by: He Xiaoxi <xxhe@alauda.io>
This commit is contained in:
		
							
								
								
									
										6
									
								
								vendor/github.com/go-openapi/spec/header.go
									
									
									
										generated
									
									
										vendored
									
									
								
							
							
						
						
									
										6
									
								
								vendor/github.com/go-openapi/spec/header.go
									
									
									
										generated
									
									
										vendored
									
									
								
							| @@ -22,6 +22,10 @@ import ( | ||||
| 	"github.com/go-openapi/swag" | ||||
| ) | ||||
|  | ||||
| const ( | ||||
| 	jsonArray = "array" | ||||
| ) | ||||
|  | ||||
| // HeaderProps describes a response header | ||||
| type HeaderProps struct { | ||||
| 	Description string `json:"description,omitempty"` | ||||
| @@ -57,7 +61,7 @@ func (h *Header) Typed(tpe, format string) *Header { | ||||
|  | ||||
| // CollectionOf a fluent builder method for an array item | ||||
| func (h *Header) CollectionOf(items *Items, format string) *Header { | ||||
| 	h.Type = "array" | ||||
| 	h.Type = jsonArray | ||||
| 	h.Items = items | ||||
| 	h.CollectionFormat = format | ||||
| 	return h | ||||
|   | ||||
		Reference in New Issue
	
	Block a user