From ba0df237da987a84a820d96afa27492b9d8f76df Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=BE=84=E6=BD=AD?= Date: Fri, 29 Mar 2024 14:03:02 +0800 Subject: [PATCH] fix wasm priority logic (#897) --- pkg/ingress/config/ingress_config.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pkg/ingress/config/ingress_config.go b/pkg/ingress/config/ingress_config.go index 602557e1f..1864fe09b 100644 --- a/pkg/ingress/config/ingress_config.go +++ b/pkg/ingress/config/ingress_config.go @@ -798,7 +798,9 @@ func (m *IngressConfig) convertIstioWasmPlugin(obj *higressext.WasmPlugin) (*ext PluginConfig: obj.PluginConfig, PluginName: obj.PluginName, Phase: extensions.PluginPhase(obj.Phase), - Priority: &types.Int64Value{Value: int64(obj.GetPriority().Value)}, + } + if obj.GetPriority() != nil { + result.Priority = &types.Int64Value{Value: int64(obj.GetPriority().Value)} } if result.PluginConfig != nil { return result, nil