Rename values for type in NotificationRecipient to make it easier to differentiate them from notification_level
Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.
During our research for the cause of gitlab-ce#56861 we were confused by the values used for notification_level and type. They were named in a similar fashion which confuses readers of the code and e.g. makes reasoning about methods like https://gitlab.com/gitlab-org/gitlab-ce/blob/master/app/models/notification_recipient.rb#L48 more difficult.
Even a slight change in wording might make sense here as suggested by @smcgivern : https://gitlab.com/gitlab-org/gitlab-ce/issues/60453#note_161660674
So we should evaluate new names for type and maybe refactor the code in NotificationRecipient so it is easier to find possible bugs.
Edited by 🤖 GitLab Bot 🤖