From 5bc5aa28a205c300e80956a257372bc2a6fcf6a7 Mon Sep 17 00:00:00 2001 From: Eric Date: Thu, 2 Oct 2014 11:50:30 +0200 Subject: Fixed more ever changing output in powerconnect model, only shows up on some firmware versions --- lib/oxidized/model/powerconnect.rb | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/oxidized/model/powerconnect.rb b/lib/oxidized/model/powerconnect.rb index 6a743db..a1fe229 100644 --- a/lib/oxidized/model/powerconnect.rb +++ b/lib/oxidized/model/powerconnect.rb @@ -14,11 +14,12 @@ class PowerConnect < Oxidized::Model end cmd 'show version' do |cfg| - comment cfg + cfg = cfg.split("\n").select { |line| not line[/Up\sTime/] } + comment cfg.join("\n") + "\n" end cmd 'show system' do |cfg| - cfg = cfg.split("\n").select { |line| not line[/Up Time/] } + cfg = cfg.split("\n").select { |line| not line[/Up\sTime/] } cfg = cfg[0..-28]<<" " comment cfg.join("\n") end -- cgit v1.2.1