From 46ad3c65704efce141e63300a15fb31b1bbf63ec Mon Sep 17 00:00:00 2001 From: Miguel Date: Thu, 1 Sep 2016 15:48:52 -0500 Subject: [PATCH] Remove @id's from the decode output. It is strange to have the objects you created with an @id in the hash even after decoding. --- lib/jsog.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/jsog.rb b/lib/jsog.rb index 7b8fd16..2066ac8 100644 --- a/lib/jsog.rb +++ b/lib/jsog.rb @@ -87,7 +87,7 @@ def decode_object(encoded, found) found[id.to_s] = result if id # be defensive if someone uses numbers in violation of the spec encoded.each do |key, value| - result[key] = do_decode(value, found) + result[key] = do_decode(value, found) unless key == '@id' end return result