diff --git a/waitlist/utility/swagger/eve/__init__.py b/waitlist/utility/swagger/eve/__init__.py index a60ca446..1aeaeadd 100644 --- a/waitlist/utility/swagger/eve/__init__.py +++ b/waitlist/utility/swagger/eve/__init__.py @@ -91,7 +91,6 @@ def get_esi_client_for_account(account: Account, noauth: bool = False) -> EsiCli return EsiClient(timeout=10, headers={'User-Agent': 'Bruce Warhead IncWaitlist/'+version}) security = EsiSecurity( - get_api(), crest_return_url, crest_client_id, crest_client_secret diff --git a/waitlist/utility/swagger/eve/fleet/__init__.py b/waitlist/utility/swagger/eve/fleet/__init__.py index 2eed93da..6cc0ef24 100644 --- a/waitlist/utility/swagger/eve/fleet/__init__.py +++ b/waitlist/utility/swagger/eve/fleet/__init__.py @@ -1,5 +1,6 @@ from pyswagger import App +from waitlist.utility.swagger import get_api from waitlist.utility.swagger.eve import get_esi_client, ESIResponse, \ get_expire_time, make_error_response from waitlist.utility.swagger.eve.fleet.responses import EveFleet, EveFleetWings, \ @@ -18,10 +19,10 @@ def __init__(self, fleet_id: int, client: EsiClient = None) -> None: self.__fleetID: int = fleet_id if client is None: self.__client: EsiClient = get_esi_client() - self.__api: App = self.__client.security.app + self.__api: App = get_api() else: self.__client: EsiClient = client - self.__api: App = self.__client.security.app + self.__api: App = get_api() def get_member(self) -> ESIResponse: response = self.__client.request(self.__api.op['get_fleets_fleet_id_members'](fleet_id=self.__fleetID)) diff --git a/waitlist/utility/swagger/evemail.py b/waitlist/utility/swagger/evemail.py index 6373123e..078d06a9 100644 --- a/waitlist/utility/swagger/evemail.py +++ b/waitlist/utility/swagger/evemail.py @@ -83,6 +83,7 @@ def open_mail(recipients: Sequence[int], body: str, subject: str, to_corp_or_all payload['recipients'] = [0] client = get_esi_client() + app = get_api() response = client.request(client.security.app.op['post_ui_openwindow_newmail'](new_mail=payload)) if response.status == 204: return ESIResponse(get_expire_time(response), response.status, None)