diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-10-11 15:09:17 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-10-11 15:09:17 +0300 |
commit | fd31bd1fc7954f69025d8e6bbe7f772ea9fb4bb0 (patch) | |
tree | cd6cc3ac0ec8123e41cb1edc81448f3a5140a14c /app/events/projects | |
parent | 988375009f3393c7db4944b707b9989d6e9b794e (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/events/projects')
-rw-r--r-- | app/events/projects/project_attributes_changed_event.rb | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/app/events/projects/project_attributes_changed_event.rb b/app/events/projects/project_attributes_changed_event.rb index e00480782a0..f7c27fa65e6 100644 --- a/app/events/projects/project_attributes_changed_event.rb +++ b/app/events/projects/project_attributes_changed_event.rb @@ -2,6 +2,11 @@ module Projects class ProjectAttributesChangedEvent < ::Gitlab::EventStore::Event + PAGES_RELATED_ATTRIBUTES = %w[ + pages_https_only + visibility_level + ].freeze + def schema { 'type' => 'object', @@ -14,5 +19,11 @@ module Projects 'required' => %w[project_id namespace_id root_namespace_id attributes] } end + + def pages_related? + PAGES_RELATED_ATTRIBUTES.any? do |attribute| + data[:attributes].include?(attribute) + end + end end end |