From f20c106a57cbbef68a8c65fa8afa1ae0152bbf86 Mon Sep 17 00:00:00 2001 From: Stefano Pigozzi Date: Thu, 28 May 2020 16:54:43 +0200 Subject: [PATCH] Fix steampowered commands --- royalpack/commands/steammatch.py | 4 ++-- royalpack/commands/steampowered.py | 5 +++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/royalpack/commands/steammatch.py b/royalpack/commands/steammatch.py index 99d27f80..25dc7e8a 100644 --- a/royalpack/commands/steammatch.py +++ b/royalpack/commands/steammatch.py @@ -1,5 +1,5 @@ from typing import * -import steam +import steam.webapi import requests.exceptions import royalnet.commands as rc import royalnet.utils as ru @@ -57,7 +57,7 @@ class SteammatchCommand(rc.Command): super().__init__(interface) if "Steam" not in self.config or "web_api_key" not in self.config["Steam"]: raise rc.ConfigurationError("[c]Steam.web_api_key[/c] config option is missing!") - self._api = steam.WebAPI(self.config["Steam"]["web_api_key"]) + self._api = steam.webapi.WebAPI(self.config["Steam"]["web_api_key"]) async def run(self, args: rc.CommandArgs, data: rc.CommandData) -> None: users = [] diff --git a/royalpack/commands/steampowered.py b/royalpack/commands/steampowered.py index a29f1e82..900d29ff 100644 --- a/royalpack/commands/steampowered.py +++ b/royalpack/commands/steampowered.py @@ -1,5 +1,6 @@ from typing import * -import steam +import steam.steamid +import steam.webapi import datetime import royalnet.commands as rc import royalnet.utils as ru @@ -18,7 +19,7 @@ class SteampoweredCommand(rc.Command): super().__init__(interface) if "Steam" not in self.config or "web_api_key" not in self.config["Steam"]: raise rc.ConfigurationError("[c]Steam.web_api_key[/c] config option is missing!") - self._api = steam.WebAPI(self.config["Steam"]["web_api_key"]) + self._api = steam.webapi.WebAPI(self.config["Steam"]["web_api_key"]) @staticmethod def _display(account: Steam):