From 00aa567eda07ae1ce9cc26ee21bf209a6eb27114 Mon Sep 17 00:00:00 2001 From: LukasK13 Date: Thu, 16 Apr 2020 09:57:01 +0200 Subject: [PATCH] Code clean up --- esbo_etc/classes/config.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/esbo_etc/classes/config.py b/esbo_etc/classes/config.py index 198f8c0..7444460 100644 --- a/esbo_etc/classes/config.py +++ b/esbo_etc/classes/config.py @@ -55,23 +55,23 @@ class Configuration(object): """ conf = None - def __init__(self, filename="esbo-etc_defaults.xml"): + def __init__(self, file="esbo-etc_defaults.xml"): """ Parse a XML configuration file. Parameters ---------- - filename : str + file : str configuration file to parse """ # Check if configuration file exists - if not os.path.exists(filename): - error("Configuration file '" + filename + "' doesn't exist.") + if not os.path.exists(file): + error("Configuration file '" + file + "' doesn't exist.") # Read configuration file - logging.info("Reading configuration from file '" + filename + "'.") - self.conf = self.parser(eT.parse(filename).getroot()) + logging.info("Reading configuration from file '" + file + "'.") + self.conf = self.parser(eT.parse(file).getroot()) self.calc_metaoptions()