Skip to content

Commit

Permalink
Update DomoticzDB.py
Browse files Browse the repository at this point in the history
  • Loading branch information
pipiche38 authored Jan 14, 2025
1 parent b7bd513 commit 707188b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Classes/DomoticzDB.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,10 +90,10 @@ def extract_username_password(self, url_base_api):
credentials, host_port = items
if credentials.startswith("https://"):
proto = "https"
credentials = credentials[8:] # Remove 'https://'
elif credentials.startswith("http://"):
credentials = credentials[8:] # Remove proto
elif credentials.startswith("http://"): # noqa: S5332
proto = "http"
credentials = credentials[7:] # Remove 'http://'
credentials = credentials[7:] # Remove proto
else:
self.logging("Error", f"Unsupported protocol in URL: {url_base_api}")
return None, None, None, None
Expand Down

0 comments on commit 707188b

Please sign in to comment.