From 9ee7940a87bee5df1db02c51c78d1339fa6a62f4 Mon Sep 17 00:00:00 2001 From: viehlieb Date: Fri, 20 Jan 2023 13:58:05 +0100 Subject: [PATCH] add next keyword to really catch every reutrn --- lib/foodsoft_article_import/borkenstein.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/foodsoft_article_import/borkenstein.rb b/lib/foodsoft_article_import/borkenstein.rb index c8d4f20..409de20 100644 --- a/lib/foodsoft_article_import/borkenstein.rb +++ b/lib/foodsoft_article_import/borkenstein.rb @@ -33,14 +33,14 @@ module FoodsoftArticleImport end # check if the line is empty - unless row[1].blank? || row[1] == "-" + next if row[1].blank? || row[1] == "-" # Split string and remove beginning " matched = row[2].gsub(/^\"/, "").gsub(/\"$/, "").match(REGEX[:main]) if matched.nil? puts "No regular article data for #{row[1]}: #{row[2]}" - + next else name, units, price_high, price_low = matched.captures