mirror of
https://github.com/YunoHost/package_linter.git
synced 2024-09-03 20:06:12 +02:00
Additional check to avoid trying to read binary file in some edge case
This commit is contained in:
parent
fbcdf54cdf
commit
f99f2ff5a1
1 changed files with 1 additions and 1 deletions
|
@ -144,7 +144,7 @@ class App():
|
||||||
#
|
#
|
||||||
|
|
||||||
for filename in os.listdir(self.path + "/conf"):
|
for filename in os.listdir(self.path + "/conf"):
|
||||||
if not os.path.isfile(self.path + "/conf/" + filename):
|
if not os.path.isfile(self.path + "/conf/" + filename) or "nginx" not in filename:
|
||||||
continue
|
continue
|
||||||
content = open(self.path + "/conf/" + filename).read()
|
content = open(self.path + "/conf/" + filename).read()
|
||||||
if "location" in content and "add_header" in content:
|
if "location" in content and "add_header" in content:
|
||||||
|
|
Loading…
Reference in a new issue