From 38709c789e430d44fac60e88c9f02000758fedbb Mon Sep 17 00:00:00 2001 From: AJ ONeal Date: Thu, 11 Feb 2016 13:34:40 -0500 Subject: [PATCH] don't add 'undefined' values --- index.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/index.js b/index.js index 4d298e7..19ac5c3 100644 --- a/index.js +++ b/index.js @@ -117,6 +117,12 @@ function stringifyPythonConf(obj, cb) { var num = obj.__keys[key]; var comment = ''; + if ('undefined' === typeof pyval) { + if ('number' === typeof num) { + obj.__lines[num] = "___DELETE_ME___"; + } + return; + } if ('number' !== typeof num) { obj.__lines.push(pykey + ' = ' + pyval);