Resolve "Extract logic of who should receive notification into separate classes"
What does this MR do?
Solve the problems mentioned in #27477 (closed) :
As noted in https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/6813#note_16937503:
all the logic related to who's watching something, or who should be notified, ideally should be placed in a separate class, not inside the service responsible for notifications
Also, methods name will need to be improved:
For example, this method doesn't return a
setting
, but returnsusers
. And other methods that haveusers
in the name actually returnuser_ids
...
Are there points in the code the reviewer needs to double check?
Why was this MR needed?
Reduce technical debt.
Screenshots (if relevant)
Does this MR meet the acceptance criteria?
[ ] Changelog entry added[ ] Documentation created/updated[ ] API support added- Tests
-
Added for this feature/bug -
All builds are passing
-
-
Conform by the merge request performance guides -
Conform by the style guides -
Branch has no merge conflicts with master
(if it does - rebase it please) [ ] Squashed related commits together
What are the relevant issue numbers?
Closes #27477 (closed)