ignore error if no readme found
This commit is contained in:
parent
34726552d7
commit
b439da96a2
1 changed files with 5 additions and 2 deletions
|
@ -193,8 +193,11 @@ def load(variables):
|
|||
return keys
|
||||
|
||||
def getLavalinkVersion():
|
||||
with open(path.join(path.dirname(path.dirname(__file__)), "lavalink/README.md"), "r") as file:
|
||||
ver = findall(r'Version \*\*(\d+.+)\*\*', file.readlines()[2])
|
||||
try:
|
||||
with open(path.join(path.dirname(path.dirname(__file__)), "lavalink/README.md"), "r") as file:
|
||||
ver = findall(r'Version \*\*(\d+.+)\*\*', file.readlines()[2])
|
||||
except:
|
||||
return None
|
||||
if len(ver) == 1:
|
||||
return ver[0]
|
||||
else:
|
||||
|
|
Reference in a new issue