Attempt to fix credentials not being set in gui

This commit is contained in:
Bernd Schoolmann 2024-05-10 11:31:24 +02:00
parent f869e9afff
commit 9fbf1a08ee
No known key found for this signature in database
2 changed files with 4 additions and 4 deletions

View File

@ -52,9 +52,9 @@ class GoldwardenLoginApp(Adw.Application):
server = self.server_row.get_text() server = self.server_row.get_text()
goldwarden.set_url(server) goldwarden.set_url(server)
if client_id != "": if client_id != "":
goldwarden.set_client_id(client_id) print("set client id result", goldwarden.set_client_id(client_id.strip()))
if client_secret != "": if client_secret != "":
goldwarden.set_client_secret(client_secret) print("set client secret result", goldwarden.set_client_secret(client_secret.strip()))
goldwarden.login_with_password(email, "") goldwarden.login_with_password(email, "")
self.window.close() self.window.close()

View File

@ -81,10 +81,10 @@ def get_environment():
return None return None
def set_client_id(client_id): def set_client_id(client_id):
send_authenticated_command(f"config set-client-id \"{client_id}\"") return send_authenticated_command(f"config set-client-id {client_id}")
def set_client_secret(client_secret): def set_client_secret(client_secret):
send_authenticated_command(f"config set-client-secret \"{client_secret}\"") return send_authenticated_command(f"config set-client-secret {client_secret}")
def login_with_password(email, password): def login_with_password(email, password):
result = send_authenticated_command(f"vault login --email {email}") result = send_authenticated_command(f"vault login --email {email}")