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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
e8a767a4
Commit
e8a767a4
authored
Aug 27, 2020
by
Arturo Herrero
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Combine default_value_for together
parent
3e4e6327
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
2 deletions
+1
-2
app/models/service.rb
app/models/service.rb
+1
-2
No files found.
app/models/service.rb
View file @
e8a767a4
...
...
@@ -26,6 +26,7 @@ class Service < ApplicationRecord
default_value_for
:active
,
false
default_value_for
:alert_events
,
true
default_value_for
:category
,
'common'
default_value_for
:commit_events
,
true
default_value_for
:confidential_issues_events
,
true
default_value_for
:confidential_note_events
,
true
...
...
@@ -81,8 +82,6 @@ class Service < ApplicationRecord
scope
:alert_hooks
,
->
{
where
(
alert_events:
true
,
active:
true
)
}
scope
:deployment
,
->
{
where
(
category:
'deployment'
)
}
default_value_for
:category
,
'common'
def
activated?
active
end
...
...
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