From 2514906bd7374270f4d2f22e1819f82c54211c13 Mon Sep 17 00:00:00 2001 From: Atlante45 Date: Fri, 30 May 2014 17:25:42 -0700 Subject: [PATCH] Fixed minor issue in currentAPI.js --- examples/currentAPI.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/examples/currentAPI.js b/examples/currentAPI.js index f926b4a02c..fe562887f9 100644 --- a/examples/currentAPI.js +++ b/examples/currentAPI.js @@ -11,6 +11,10 @@ function listKeys(string, object) { + if (string == "listKeys") { + return; + } + if (typeof(object) != "object") { print(typeof(object) + " " + string); return; @@ -18,9 +22,7 @@ function listKeys(string, object) { var keys = Object.keys(object); for (var i = 0; i < keys.length; ++i) { - if (string == "listKeys") { - return; - } else if (string == "") { + if (string == "") { listKeys(keys[i], object[keys[i]]); } else { listKeys(string + "." + keys[i], object[keys[i]]);