Omnibus commited on
Commit
f9d9756
·
1 Parent(s): 53b8931

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -2
app.py CHANGED
@@ -26,9 +26,11 @@ def query2(fetch_url):
26
  dictionary=response.json()
27
  #json_object = json.dumps(dictionary, indent=4)
28
  # Writing to sample.json
29
- json_object=json.load(dictionary)
30
  with open("sample.json", "w") as outfile:
31
- json.dumps(json_object, outfile, indent=4)
 
 
32
 
33
  #outfile.write(dictionary)
34
  return "sample.json"
 
26
  dictionary=response.json()
27
  #json_object = json.dumps(dictionary, indent=4)
28
  # Writing to sample.json
29
+ #json_object=json.load(dictionary)
30
  with open("sample.json", "w") as outfile:
31
+ #json.dumps(response_dict, indent=4, sort_keys=True)
32
+
33
+ json.dump(dictionary, outfile)
34
 
35
  #outfile.write(dictionary)
36
  return "sample.json"