style: some weird black code reformatting

This commit is contained in:
Macintxsh 2025-05-21 04:34:01 +03:00
parent 673a3768b8
commit 9ad1ce38ee
Signed by: mctaylors
GPG key ID: 4EEF4F949A266EE2
5 changed files with 82 additions and 53 deletions

View file

@ -12,9 +12,11 @@ class _General:
sourceurl: Optional[str]
def __init__(self):
self.token = _c.get('General', 'Token')
self.sourceurl = _c.get('General', 'SourceUrl')
if not self.sourceurl.startswith("http://") and not self.sourceurl.startswith("https://"):
self.token = _c.get("General", "Token")
self.sourceurl = _c.get("General", "SourceUrl")
if not self.sourceurl.startswith("http://") and not self.sourceurl.startswith(
"https://"
):
self.sourceurl = None
@ -24,8 +26,8 @@ class _App:
hostname: str
def __init__(self):
self.name = _c.get('App', 'Name')
self.host = _c.get('App', 'Host')
self.name = _c.get("App", "Name")
self.host = _c.get("App", "Host")
# noinspection PyBroadException
try:
response = requests.get(f"http://{self.host}/status.json")
@ -34,7 +36,7 @@ class _App:
except:
print("Unable validate App.Host in config.ini.")
exit(1)
self.hostname = _c.get('App', 'HostName')
self.hostname = _c.get("App", "HostName")
if not self.hostname:
self.hostname = self.host