From 4b2765461e0832c9da8f5f50c9c52c9b732f8eaf Mon Sep 17 00:00:00 2001 From: "C.J. May" Date: Wed, 8 Jan 2025 00:39:14 -0600 Subject: [PATCH] fix variable name --- src/restic_compose_backup/containers_db.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/restic_compose_backup/containers_db.py b/src/restic_compose_backup/containers_db.py index 199f1ee..f82bf27 100644 --- a/src/restic_compose_backup/containers_db.py +++ b/src/restic_compose_backup/containers_db.py @@ -15,7 +15,7 @@ class MariadbContainer(Container): def get_credentials(self) -> dict: """dict: get credentials for the service""" password = self.get_config_env('MARIADB_ROOT_PASSWORD') - if root_password is not None: + if password is not None: username = "root" else: username = self.get_config_env('MARIADB_USER') @@ -81,7 +81,7 @@ class MysqlContainer(Container): def get_credentials(self) -> dict: """dict: get credentials for the service""" password = self.get_config_env('MYSQL_ROOT_PASSWORD') - if root_password is not None: + if password is not None: username = "root" else: username = self.get_config_env('MYSQL_USER')