From 52c32ffb19bfd9c1ceb4294b7762d7849b545ab1 Mon Sep 17 00:00:00 2001 From: Kyrre Havik Date: Wed, 6 Jul 2022 20:51:13 +0200 Subject: [PATCH] fix: should skip fields that are nil fixes #12 --- eksporter.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eksporter.rb b/eksporter.rb index 3cae143..4b9672f 100755 --- a/eksporter.rb +++ b/eksporter.rb @@ -37,7 +37,7 @@ def delete_field(resource, fields) delete_field(res, [field]) end else - resource.delete(field) + resource.delete(field) if resource end else delete_field(resource[field], fields)