fix: removed redundant condition

Co-authored-by: Ankush Menat <ankushmenat@gmail.com>
This commit is contained in:
Shariq Ansari 2023-06-23 16:31:55 +05:30 committed by GitHub
parent 3f792a80b1
commit fe27b8c7e0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -76,7 +76,7 @@ class Webhook(Document):
frappe.throw(_("Same Field is entered more than once"))
def validate_secret(self):
if self.enable_security and self.webhook_secret:
if self.enable_security:
try:
self.get_password("webhook_secret", False).encode("utf8")
except Exception: