From e291b73ba49e5c4db7a64f123885a38997156ff5 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Alexis=20Laferri=C3=A8re?= Date: Sat, 1 Feb 2014 23:47:06 -0500 Subject: [PATCH] lib: do not ignore key/values when value is null in Map::join MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Alexis Laferrière --- lib/standard/string.nit | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/standard/string.nit b/lib/standard/string.nit index e159dfc..4326d04 100644 --- a/lib/standard/string.nit +++ b/lib/standard/string.nit @@ -1060,15 +1060,15 @@ redef class Map[K,V] var i = iterator var k = i.key var e = i.item - if e != null then s.append("{k}{couple_sep}{e}") - + s.append("{k}{couple_sep}{e or else ""}") + # Concat other items i.next while i.is_ok do s.append(sep) k = i.key e = i.item - if e != null then s.append("{k}{couple_sep}{e}") + s.append("{k}{couple_sep}{e or else ""}") i.next end return s.to_s -- 1.7.9.5