From 0ed3e5d54703b73739083c5804a4304e3e24bc32 Mon Sep 17 00:00:00 2001 From: Omar Roth Date: Sat, 24 Mar 2018 20:57:57 -0500 Subject: [PATCH] Refactor arg_array --- src/helpers.cr | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/helpers.cr b/src/helpers.cr index ef70c630..a8de6b0a 100644 --- a/src/helpers.cr +++ b/src/helpers.cr @@ -388,9 +388,8 @@ end def arg_array(array) args = [] of String - (1..array.size).each { |i| args << "($#{i})," } - args = args.join("") - args = args.chomp(",") + (1..array.size).each { |i| args << "($#{i})" } + args = args.join(",") return args end