def validate(self):
    if (self.notify_on_login and (not self.expire_notification_on)):
        self.expire_notification_on = frappe.utils.add_days(self.creation, 7)
def validate(self):
    if (self.notify_on_login and (not self.expire_notification_on)):
        self.expire_notification_on = frappe.utils.add_days(self.creation, 7)