-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Add method to clear notification when user is deletd #32260
Conversation
e2aa77e
to
032d6d8
Compare
Fixes -> owncloud/password_policy#69 |
032d6d8
to
b42084e
Compare
Codecov Report
@@ Coverage Diff @@
## master #32260 +/- ##
============================================
+ Coverage 64.01% 64.01% +<.01%
- Complexity 18559 18562 +3
============================================
Files 1171 1171
Lines 69834 69841 +7
Branches 1267 1267
============================================
+ Hits 44704 44711 +7
Misses 24761 24761
Partials 369 369
Continue to review full report at Codecov.
|
lib/public/Notification/IApp.php
Outdated
/** | ||
* @param $uid | ||
* @return null | ||
* @since 10.1.0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you can put 10.0.10 here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PHPDoc is incomplete
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
see comment
Added a method to clear notification entry of user when the user is deleted from oC. Signed-off-by: Sujith H <sharidasan@owncloud.com>
b42084e
to
fefb2ca
Compare
What are the reasons to provide the solution here? This implies that the core's notification manager knows that the notification is stored by the apps, which implies that is expected that the apps store notifications somewhere, which leads to store duplicate information (by different apps). Core doesn't need to know whether the notifications are being stored. If the notifications app or any other provider stores notifications it's their own responsability to clean them. I'd prefer to move the solution to the notification app: just listen the delete event there and remove the stored notifications. No need to change the core's interface. |
In fact you are right, the core should not bother about the changes I made in this PR. The notification app should listen to the event and then do the action, i.e, to remove the entry of the user from the table. |
@sharidas please link to your new PR in the notifications app then close |
The notification PR owncloud/notifications#221 is sufficient to achieve the result. Hence closing this PR. |
Added a method to clear notification entry of user
when the user is deleted from oC.
Signed-off-by: Sujith H sharidasan@owncloud.com
Description
User entries from notification table should be deleted, once the user is deleted from oC.
Related Issue
Motivation and Context
User entries from notification table should be deleted, once the user is deleted from oC.
How Has This Been Tested?
Screenshots (if appropriate):
Types of changes
Checklist:
Open tasks: