From f674a2b6573c2be6165e8dbd2013784520f20885 Mon Sep 17 00:00:00 2001 From: "Ruben S. Montero" Date: Fri, 26 Apr 2019 15:48:38 +0200 Subject: [PATCH] Feature #3263: Fix Ruby 1.9 with SymbolArray --- share/linters/.rubocop.yml | 4 ++++ src/onedb/fsck/network.rb | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/share/linters/.rubocop.yml b/share/linters/.rubocop.yml index 416dea80e2d..7f7a5f809cd 100644 --- a/share/linters/.rubocop.yml +++ b/share/linters/.rubocop.yml @@ -718,6 +718,10 @@ Style/SymbolProc: Style/StderrPuts: Enabled: false +#This breaks Ruby 1.9 +Style/SymbolArray: + Enabled: false + ###### # LINT ###### diff --git a/src/onedb/fsck/network.rb b/src/onedb/fsck/network.rb index b376d619fc6..1da2c44f762 100644 --- a/src/onedb/fsck/network.rb +++ b/src/onedb/fsck/network.rb @@ -530,7 +530,7 @@ def calculate_new_leases(leases, ids, addrs, counters, error) end # Things that can't be fixed - %i[ip ip6_global ip6_link ip6_ula].each do |key| + [:ip, :ip6_global, :ip6_link, :ip6_ula].each do |key| next if counter_lease[key] == lease[key] log_error("VNet #{ids[:o]} AR #{ids[:ar]} has a wrong " \