We have teachers enrolled in a course with the teacher role and this teacher role has mod/quiz:emailnotifysubmission capability set. Thereby, teachers get a notification mail each time a student submits a quiz solution.
Now, some of our teachers want to disable these notification mails for quizes. This should be possible on the "My Profile settings -> Messaging" page. On this page, admins have a "Notification of quiz submissions" item which works as desired, but teachers lack this item.
Looking into /mod/quiz/db/messages.php, I see that mod/quiz:emailnotifysubmission capability is needed to edit this messageprovider item. As soon as I assign the teacher role as global role to the user, he sees the "Notification of quiz submissions" item in the messaging settings.
For my understanding the "Notification of quiz submissions" item should be available on the messaging settings page as soon as a user has the teacher role in any course. Is this a bug or am I missing something?