-
Notifications
You must be signed in to change notification settings - Fork 4k
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: headless api client remove/refetch query scenarios #5021
Conversation
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.
@vichustephen please look into failing tests
@jainpawan21 I need a little help here. Since I changed how the methods must be called , the test cases is an expected behaviour. Should I update the test cases also ? |
Yes please update the tests accordingly |
@BiswaViraj Could you please help @vichustephen |
@vichustephen , Yes you'll need to update the test cases as well, as the methods have been changed |
@jainpawan21 @BiswaViraj I have updated the test cases |
What change does this PR introduce?
Here , I have fixed the issues over remove/refetch scenarios in Headless api methods
Why was this change needed?
In headless API we use a set of events like markAs, listenNotificationReceive, deleteNotification, deleteNotifications,etc. While we use these methods to integrate our custom component with novu we have found some issues. When we make changes to notifications it should refetch the queries at certain events and remove them for certain events.
Closes #5011
: https://github.com/novuhq/novu/issues/5011Other information (Screenshots)
I have tested the scenarios in my local environment.