diff --git a/util/logger.js b/util/logger.js
index 47d27d1d..0189d57a 100644
--- a/util/logger.js
+++ b/util/logger.js
@@ -42,21 +42,24 @@ if (process.env.FWDEBUG) {
 }
 
 const keysToRedact = new Set(["password", "passwd", "psk", "key", "psks"]);
-// pass in function arguments object and returns string with whitespaces
 function redactLog(obj, redactRequired = false) {
   if (!obj)
     return obj;
   // obj should be either object or array
+  const objCopy = _.isArray(obj) ? [] : Object.create(obj);
   try {
     for (const key of Object.keys(obj)) {
       if (_.isObject(obj[key]) || _.isArray(obj[key]))
-        redactLog(obj[key], redactRequired || keysToRedact.has(key));
+        objCopy[key] = redactLog(obj[key], redactRequired || keysToRedact.has(key));
       else {
         if (redactRequired || keysToRedact.has(key))
-          obj[key] = "*** redacted ***";
+          objCopy[key] = "*** redacted ***";
+        else
+          objCopy[key] = obj[key];
       }
     }
   } catch (err) {}
+  return objCopy;
 }
 
 // pass in function arguments object and returns string with whitespaces
@@ -66,8 +69,8 @@ function argumentsToString(v) {
   for (var k in args) {
     if (typeof args[k] === "object") {
       // args[k] = JSON.stringify(args[k]);
-      args[k] = JSON.parse(JSON.stringify(args[k]));
-      redactLog(args[k]);
+      if (_.isArray(args[k]) || _.isObject(args[k]))
+        args[k] = redactLog(args[k]);
       args[k] = require('util').inspect(args[k], false, null, true);
     }
   }