The interface grid keeps the node interface data in the record even if
BGP disables the IPv6 column via 'hasIpv6Support=false'. As getValue()
serializes the full record data, BGP interfaces could still submit an
'ip6' property. This results in the error 'format error
interfaces[0].ip6: property is not defined in schema'.

Skip 'ip6' during serialization when IPv6 support is disabled for the
panel.

Signed-off-by: Lukas Sichert <[email protected]>
---
 www/manager6/sdn/fabrics/InterfacePanel.js | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/www/manager6/sdn/fabrics/InterfacePanel.js 
b/www/manager6/sdn/fabrics/InterfacePanel.js
index f07e7859..74781267 100644
--- a/www/manager6/sdn/fabrics/InterfacePanel.js
+++ b/www/manager6/sdn/fabrics/InterfacePanel.js
@@ -174,7 +174,10 @@ Ext.define('PVE.sdn.Fabric.InterfacePanel', {
                     continue;
                 }
 
-                if (['type', 'isDisabled'].includes(key)) {
+                if (
+                    ['type', 'isDisabled'].includes(key) ||
+                    (key === 'ip6' && !me.hasIpv6Support)
+                ) {
                     continue;
                 }
 
-- 
2.47.3




Reply via email to