lib/json: clear error list on each call to deserialize
authorAlexis Laferrière <alexis.laf@xymus.net>
Mon, 29 Jun 2015 02:14:46 +0000 (22:14 -0400)
committerAlexis Laferrière <alexis.laf@xymus.net>
Mon, 29 Jun 2015 02:47:06 +0000 (22:47 -0400)
Signed-off-by: Alexis Laferrière <alexis.laf@xymus.net>

lib/json/serialization.nit

index f2758b3..f7c161e 100644 (file)
@@ -311,7 +311,11 @@ class JsonDeserializer
                return object
        end
 
-       redef fun deserialize do return convert_object(root)
+       redef fun deserialize
+       do
+               errors.clear
+               return convert_object(root)
+       end
 end
 
 redef class Serializable