Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Léo-Paul Géneau
gitlab-ce
Commits
8947232b
Commit
8947232b
authored
Jul 10, 2017
by
Sean McGivern
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Allow passing exceptions when creating project services
parent
64701b51
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
app/models/project.rb
app/models/project.rb
+4
-2
No files found.
app/models/project.rb
View file @
8947232b
...
@@ -801,10 +801,12 @@ class Project < ActiveRecord::Base
...
@@ -801,10 +801,12 @@ class Project < ActiveRecord::Base
update_column
(
:has_external_wiki
,
services
.
external_wikis
.
any?
)
update_column
(
:has_external_wiki
,
services
.
external_wikis
.
any?
)
end
end
def
find_or_initialize_services
def
find_or_initialize_services
(
exceptions:
[])
services_templates
=
Service
.
where
(
template:
true
)
services_templates
=
Service
.
where
(
template:
true
)
Service
.
available_services_names
.
map
do
|
service_name
|
available_services_names
=
Service
.
available_services_names
-
exceptions
available_services_names
.
map
do
|
service_name
|
service
=
find_service
(
services
,
service_name
)
service
=
find_service
(
services
,
service_name
)
if
service
if
service
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment