Skip to content

A platform for community discussion. Free, open, simple.

FIX: reverts to use an observer to support loading more notifications (#9628)

Joffrey JAFFEUX70b1e9860959
diff --git a/app/assets/javascripts/discourse/app/components/user-notifications-large.js b/app/assets/javascripts/discourse/app/components/user-notifications-large.js
index 193a5b8b120..5f508780999 100644
--- a/app/assets/javascripts/discourse/app/components/user-notifications-large.js
+++ b/app/assets/javascripts/discourse/app/components/user-notifications-large.js
@@ -1,4 +1,5 @@
import MountWidget from "discourse/components/mount-widget";
+import { observes } from "discourse-common/utils/decorators";
export default MountWidget.extend({
widget: "user-notifications-large",
@@ -6,9 +7,14 @@ export default MountWidget.extend({
filter: null,
args: null,
- didReceiveAttrs() {
+ init() {
this._super(...arguments);
+ this.args = { notifications: this.notifications, filter: this.filter };
+ },
+
+ @observes("notifications.length", "[email protected]", "filter")
+ _triggerRefresh() {
this.set("args", {
notifications: this.notifications,
filter: this.filter