Skip to content

Commit

Permalink
Delete events when activity is deleted
Browse files Browse the repository at this point in the history
  • Loading branch information
moodler committed May 17, 2004
1 parent d6533f3 commit 36eb856
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions mod/assignment/lib.php
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,10 @@ function assignment_delete_instance($id) {
$result = false;
}

if (! delete_records('event', 'modulename', 'assignment', 'instance', $assignment->id)) {
$result = false;
}

return $result;
}

Expand Down
4 changes: 4 additions & 0 deletions mod/chat/lib.php
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,10 @@ function chat_delete_instance($id) {
$result = false;
}

if (! delete_records('event', 'modulename', 'chat', 'instance', $chat->id)) {
$result = false;
}

return $result;
}

Expand Down

0 comments on commit 36eb856

Please sign in to comment.