diff --git a/Netdisco/Changes b/Netdisco/Changes index d52a9fc3..314ede5c 100644 --- a/Netdisco/Changes +++ b/Netdisco/Changes @@ -14,6 +14,7 @@ * [#85] device property in _no/_only fails with error (R. Kerr) * Also prefer port filter when linking to connected devices + * Fix SQL logic in PortMAC.pm (imperfectus) 2.021001 diff --git a/Netdisco/lib/App/Netdisco/Util/PortMAC.pm b/Netdisco/lib/App/Netdisco/Util/PortMAC.pm index b656e3a5..72836397 100644 --- a/Netdisco/lib/App/Netdisco/Util/PortMAC.pm +++ b/Netdisco/lib/App/Netdisco/Util/PortMAC.pm @@ -41,7 +41,7 @@ sub get_port_macs { my $dp_macs = schema('netdisco')->resultset('DevicePort') - ->search( { mac => { '!=', [ undef, '00:00:00:00:00:00' ] } }, + ->search( { mac => { '!=' => [ -and => (undef, '00:00:00:00:00:00') ] } }, { select => [ 'mac', 'ip' ], group_by => [ 'mac', 'ip' ] } ); my $dp_cursor = $dp_macs->cursor;