Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix obsolete notifications #470

Merged
merged 1 commit into from
Mar 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions docs/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
Changelog
=========

1.5.10 (Unreleased)
----------------------
- Fix #470: Fix obsolete notifications

1.5.9 (March 14, 2024)
----------------------
- Fix #443: Fix email subject on invite/add users
Expand Down
34 changes: 34 additions & 0 deletions migrations/m240319_152508_fix_notification.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
<?php

use humhub\components\Migration;
use humhub\modules\notification\models\Notification;

/**
* Class m240319_152508_fix_notification
*/
class m240319_152508_fix_notification extends Migration
{
/**
* {@inheritdoc}
*/
public function safeUp()
{
Notification::updateAll(
['class' => 'humhub\\modules\\calendar\\notifications\\ParticipantAdded'],
['IN', 'class', [
'humhub\\modules\\calendar\\notifications\\Invited',
'humhub\\modules\\calendar\\notifications\\ForceAdd'
]]
);
}

/**
* {@inheritdoc}
*/
public function safeDown()
{
echo "m240319_152508_fix_notification cannot be reverted.\n";

return false;
}
}
2 changes: 1 addition & 1 deletion module.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"name": "Calendar",
"description": "Create one-time or recurring events, invite and manage attendees, and keep track of all your events with the Calendar module.",
"keywords": ["calendar"],
"version": "1.5.9",
"version": "1.5.10",
"humhub": {
"minVersion": "1.14"
},
Expand Down
Loading