Explorar o código

use parsedJson

AykutSarac %!s(int64=3) %!d(string=hai) anos
pai
achega
ffa5b330fe
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/containers/JsonEditor/index.tsx

+ 1 - 1
src/containers/JsonEditor/index.tsx

@@ -61,7 +61,7 @@ const JsonEditor: React.FC = () => {
         const parsedJson = parseJson(value);
 
         if (settings.autoformat) {
-          setValue(JSON.stringify(JSON.parse(value), null, 2));
+          setValue(JSON.stringify(parsedJson, null, 2));
         } else {
           setValue(value);
         }