From f9311c9878a27242d738a4a151a0071d9ec1ebfd Mon Sep 17 00:00:00 2001 From: YaYaB Date: Mon, 29 Apr 2019 15:55:55 +0200 Subject: [PATCH] Remove unused variables --- json_to_csv/json_to_csv.py | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/json_to_csv/json_to_csv.py b/json_to_csv/json_to_csv.py index 4bdaabf..2cf78e6 100644 --- a/json_to_csv/json_to_csv.py +++ b/json_to_csv/json_to_csv.py @@ -233,8 +233,6 @@ def read_jsons_chunks(file_object, chunk_size=10000): # Initialize those example = "" - c_bef = "" - c_2bef = "" continue # If we are in between 2 json examples or at the beginning elif c in ['[', ',', '\n'] and nb_bracket == 0 and nb_quotes % 2 == 0: @@ -251,10 +249,7 @@ def read_jsons_chunks(file_object, chunk_size=10000): count_escape_char = 0 # Append character to the json example example += c - - # Set previous characters - c_2bef = c_bef - c_bef = c + # If at the end of the chunk, read new chunk if k == len(chunk) - 1: chunk = file_object.read(1000000)