chore: fix issues

This commit is contained in:
Tanmoy Sarkar 2024-01-04 18:38:49 +05:30
parent 896da0afb3
commit ee8ab3da4a

View file

@ -183,12 +183,7 @@ class PushNotification:
:return: tuple[str, str] The API key and secret.
"""
notification_settings = frappe.get_doc("Push Notification Settings")
if (
notification_settings.api_key != ""
and notification_settings.api_secret != ""
and notification_settings.api_key is not None
and notification_settings.api_secret is not None
):
if notification_settings.api_key and notification_settings.api_secret:
return notification_settings.api_key, notification_settings.api_secret
else:
# Generate new credentials