Reset pass is now also ini file

This commit is contained in:
JP
2018-11-18 12:09:45 +01:00
parent 044e0733d2
commit c242a9b591
2 changed files with 2 additions and 6 deletions
+1 -4
View File
@@ -19,8 +19,6 @@ class General(object):
client_id=self.bot.tokens["redditId"]
)
self.r.read_only = True
f = open("password.txt","r")
self.rebootPW = f.readline()
def __check(self, ctx): #Todo: Is dit het porno kanaal?
return True
@@ -81,8 +79,7 @@ class General(object):
@asyncio.coroutine
def reboot(self, ctx, password=""):
""" Reboot.. """
print(self.rebootPW)
if password == self.rebootPW:
if password == self.bot.passwords["resetpassword"]:
yield from ctx.channel.send("Rebooting.. brb!")
os.execv(sys.executable, ['python3'] + sys.argv)
else: