Skip to content

Commit e21a6a6

Browse files
Harmonize TLS push file method signatures
1 parent 4fa8453 commit e21a6a6

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

src/charm.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -998,7 +998,7 @@ def _on_postgresql_pebble_ready(self, event: WorkloadEvent) -> None:
998998
return
999999

10001000
try:
1001-
self.push_tls_files_to_workload(container)
1001+
self.push_tls_files_to_workload()
10021002
for ca_secret_name in self.tls.get_ca_secret_names():
10031003
self.push_ca_file_into_workload(ca_secret_name)
10041004
except (PathError, ProtocolError) as e:
@@ -1895,10 +1895,9 @@ def _push_file_to_workload(self, container: Container, file_path: str, file_data
18951895
group=WORKLOAD_OS_GROUP,
18961896
)
18971897

1898-
def push_tls_files_to_workload(self, container: Container = None) -> bool:
1898+
def push_tls_files_to_workload(self) -> bool:
18991899
"""Uploads TLS files to the workload container."""
1900-
if container is None:
1901-
container = self.unit.get_container("postgresql")
1900+
container = self.unit.get_container("postgresql")
19021901

19031902
key, ca, cert = self.tls.get_tls_files()
19041903

0 commit comments

Comments
 (0)