Duplicate Notifications on data import

after importing an excel sheet I want to notify the user by using the database notification. so far the notifications are being created but they are created according to number of excel rows. but i want to send it once. any help please?
7 Replies
Dennis Koch
Dennis Koch2y ago
Don’t wrap it in a for loop then??
Lambertn33
Lambertn33OP2y ago
@Dennis Koch I am sending to multiple users this is why I used the foreach loop also since my users are two and if the number of rows is 20 means I am getting 40 notifications. while I was expecting to get only 2
Dennis Koch
Dennis Koch2y ago
That’s because you are sending a notification after every row creation
Lambertn33
Lambertn33OP2y ago
how can I solve this please? I tried but unfortunately i failed to solve this I am wondering if there might be another type action that can be run after the import is done
Dennis Koch
Dennis Koch2y ago
I don’t know the plugin so I can’t tell.
Dan Harrin
Dan Harrin2y ago
is there no after() function callback? this is a plugin issue
Lambertn33
Lambertn33OP2y ago
let me check @Dan Harrin if this might exist! @Dan Harrin You saved my day.. God bless you! it finally worked
Want results from more Discord servers?
Add your server