Skip to content

Commit be8934f

Browse files
committed
Merge pull request #499 from helgi/bug_498
fix(certificates): make sure domains are 0 for a cert before removing the secret
2 parents d8dc4df + 51ca2f2 commit be8934f

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

rootfs/api/models/certificate.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ def detach(self, *args, **kwargs):
204204
app = domain.app
205205

206206
# only delete if it exists and if no other domains depend on secret
207-
if len(self.domains):
207+
if len(self.domains) == 0:
208208
try:
209209
# We raise an exception when a secret doesn't exist
210210
self._scheduler._get_secret(app, name)

0 commit comments

Comments
 (0)