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
Boxiang Sun
gitlab-ce
Commits
ddb0344a
Commit
ddb0344a
authored
May 31, 2019
by
Wei-Meng Lee
Committed by
Wei-Meng Lee
May 31, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Apply reviewer suggestions
parent
ddd6f804
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
5 deletions
+4
-5
app/mailers/notify.rb
app/mailers/notify.rb
+1
-1
doc/workflow/notifications.md
doc/workflow/notifications.md
+1
-1
spec/support/shared_examples/notify_shared_examples.rb
spec/support/shared_examples/notify_shared_examples.rb
+2
-3
No files found.
app/mailers/notify.rb
View file @
ddb0344a
...
@@ -88,7 +88,7 @@ class Notify < BaseMailer
...
@@ -88,7 +88,7 @@ class Notify < BaseMailer
# Return group-specific email address if present, otherwise return global
# Return group-specific email address if present, otherwise return global
# email address
# email address
group_notification_email
.
presence
||
@current_user
.
notification_email
group_notification_email
||
@current_user
.
notification_email
end
end
# Formats arguments into a String suitable for use as an email subject
# Formats arguments into a String suitable for use as an email subject
...
...
doc/workflow/notifications.md
View file @
ddb0344a
...
@@ -23,7 +23,7 @@ Each of these settings have levels of notification:
...
@@ -23,7 +23,7 @@ Each of these settings have levels of notification:
-
Disabled: Turns off notifications.
-
Disabled: Turns off notifications.
-
Custom: Receive notifications for custom selected events.
-
Custom: Receive notifications for custom selected events.
> Introduced in GitLab 1
1.9
> Introduced in GitLab 1
2.0
You can also select an email address to receive notifications for each group you belong to.
You can also select an email address to receive notifications for each group you belong to.
...
...
spec/support/shared_examples/notify_shared_examples.rb
View file @
ddb0344a
...
@@ -60,10 +60,9 @@ shared_examples 'an email sent to a user' do
...
@@ -60,10 +60,9 @@ shared_examples 'an email sent to a user' do
end
end
end
end
context
'when project is in a sub-group'
do
context
'when project is in a sub-group'
,
:nested_groups
do
before
do
before
do
project
.
group
=
subgroup
project
.
update!
(
group:
subgroup
)
project
.
save!
end
end
it
'is sent to user\'s subgroup notification email address when set'
do
it
'is sent to user\'s subgroup notification email address when set'
do
...
...
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