diff --git a/app/models/ci/trigger_schedule.rb b/app/models/ci/trigger_schedule.rb index bb58c5102775f141a6491e589b93e904e7bea195..72716eb416b823864a36744498029516f8a827ed 100644 --- a/app/models/ci/trigger_schedule.rb +++ b/app/models/ci/trigger_schedule.rb @@ -10,7 +10,7 @@ module Ci delegate :ref, to: :trigger, allow_nil: true - validates_presence_of :trigger + validates :trigger, presence: { unless: :importing? } validates :cron, cron: true, presence: { unless: :importing? } validates :cron_timezone, cron_timezone: true, presence: { unless: :importing? } validates :ref, presence: { unless: :importing? } diff --git a/app/views/projects/triggers/_trigger.html.haml b/app/views/projects/triggers/_trigger.html.haml index 9ab0cd3486c554d8c8f820d9aac78eb12414f046..3ed1fc9ac23eba4fe4b4e913410d5d6ad4cb54e1 100644 --- a/app/views/projects/triggers/_trigger.html.haml +++ b/app/views/projects/triggers/_trigger.html.haml @@ -33,7 +33,7 @@ - if trigger.trigger_schedule.persisted? = trigger.trigger_schedule.real_next_run - else - N/A (External trigger) + None (External trigger) %td.text-right.trigger-actions - take_ownership_confirmation = "By taking ownership you will bind this trigger to your user account. With this the trigger will have access to all your projects as if it was you. Are you sure?"