Skip to content
Snippets Groups Projects
Commit f60b83ce authored by Ramon Buldó's avatar Ramon Buldó
Browse files

parse_conf: simplify conditions

From 06f58149
parent 5c402557
No related branches found
No related tags found
No related merge requests found
......@@ -77,11 +77,9 @@ class PacmanMirrors:
with open(conf_file) as fi:
for line in fi:
line = line.strip()
if line == "":
continue
if line[0] == '#' or line[0] == '\n':
continue
if '=' not in line:
if (line.startswith('#') or
line.startswith('\n') or
"=" not in line):
continue
(key, value) = [x.strip() for x in line.split('=', 1)]
if not key or not value:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment