From 155fedb7b7ae9ce3e9971cc1ad7cfcda8379baf0 Mon Sep 17 00:00:00 2001 From: Faelix Incident Handler Date: Sun, 29 Mar 2020 11:31:38 +0000 Subject: [PATCH] use yaml.SafeLoader --- event.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/event.py b/event.py index dce348a..d60e9a0 100644 --- a/event.py +++ b/event.py @@ -33,7 +33,7 @@ class Index( object ): def read( self ): indata = open( self.path, 'r', encoding = "utf-8" ).read() ( pre, yamldata, docdata ) = re.split( "^---$", indata, flags = re.MULTILINE ) - self.fields = yaml.load( yamldata ) + self.fields = yaml.load( yamldata, Loader = yaml.SafeLoader ) self.doc = docdata.strip()