Allow blank values for the notification email
By default forms do not have that value set
This commit is contained in:
parent
3032b0ae1c
commit
81ad9dde98
@ -18,7 +18,8 @@ class Form < ApplicationRecord
|
||||
validates :airtable_api_key, presence: { if: :airtable? }
|
||||
validates :airtable_app_key, presence: { if: :airtable? }
|
||||
validates :airtable_table, presence: { if: :airtable? }
|
||||
validates :notify_email, presence: true, on: :update
|
||||
validates :notify_email, presence: true, on: :update, allow_blank: true
|
||||
|
||||
# TODO: use counter_cache option on association
|
||||
def submissions_count
|
||||
@submissions_count ||= submissions.count
|
||||
|
Loading…
x
Reference in New Issue
Block a user