Skip to content

Commit

Permalink
Use yaml safe_load function
Browse files Browse the repository at this point in the history
  • Loading branch information
gunthercox committed Apr 29, 2020
1 parent 80e2272 commit 8cd8f5f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion chatterbot/corpus.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ def read_corpus(file_name):
Read and return the data from a corpus json file.
"""
with io.open(file_name, encoding='utf-8') as data_file:
return yaml.load(data_file)
return yaml.safe_load(data_file)


def list_corpus_files(dotted_path):
Expand Down

0 comments on commit 8cd8f5f

Please sign in to comment.