Skip to content

Commit

Permalink
fix moderator notification of new course #97
Browse files Browse the repository at this point in the history
  • Loading branch information
patrickakk committed Feb 28, 2024
1 parent 626fefb commit ba1d5cb
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion RELEASE_NOTES.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
*Release date: ...*

### Bug fixes
- a
- Moderator does not receive notification of new course #97

### Changes
- b
Expand Down
2 changes: 1 addition & 1 deletion src/Controller/CoursesController.php
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ public function add()
->where(['Courses.id' => $course->id])
->contain(['Institutions', 'CourseTypes'])
->first();
$admins = $this->Users->getModerators(null, true);
$admins = $this->Users->getModerators($courseData->country_id, true);
foreach ($admins as $admin) {
$this->getMailer('Course')->send('notifyAdmin', [$courseData, $admin->email]);
}
Expand Down

0 comments on commit ba1d5cb

Please sign in to comment.