mirror of
https://github.com/home-assistant/core.git
synced 2025-12-24 21:06:19 +00:00
Use literal string interpolation in integrations X-Z (f-strings) (#26395)
This commit is contained in:
committed by
Pascal Vizeli
parent
445c741b30
commit
dae6895a95
@@ -143,7 +143,7 @@ def _retrieve_list(host, token, **kwargs):
|
||||
|
||||
def _get_token(host, username, password):
|
||||
"""Get authentication token for the given host+username+password."""
|
||||
url = "http://{}/cgi-bin/luci/api/xqsystem/login".format(host)
|
||||
url = f"http://{host}/cgi-bin/luci/api/xqsystem/login"
|
||||
data = {"username": username, "password": password}
|
||||
try:
|
||||
res = requests.post(url, data=data, timeout=5)
|
||||
|
||||
Reference in New Issue
Block a user