Move to a central login() method
This commit is contained in:
@@ -9,6 +9,7 @@ import base64
|
||||
import json
|
||||
import os
|
||||
import config
|
||||
import webbrowser
|
||||
|
||||
import eos.db
|
||||
import datetime
|
||||
@@ -179,6 +180,12 @@ class Esi(object):
|
||||
if char.esi_client is not None:
|
||||
char.esi_client.security.update_token(tokenResponse)
|
||||
|
||||
def login(self):
|
||||
# Switch off how we do things here depending on the mode of authentication
|
||||
uri = self.startServer()
|
||||
webbrowser.open(uri)
|
||||
wx.PostEvent(self.mainFrame, GE.SsoLoggingIn())
|
||||
|
||||
def stopServer(self):
|
||||
pyfalog.debug("Stopping Server")
|
||||
self.httpd.stop()
|
||||
|
||||
Reference in New Issue
Block a user