Events.js previously firing, now it is not

Hello, I’m stuck on the same issue. The adding to the cart is being done using the full page instead of the quickAdd window. But still, the event is not being fired. here is the code for events.js file:
I want to make an api call after the purchase is completed, for testing purposes first, I tried to simply log the event and add it to backendLog collection as well
because some other posts suggested to do so to see if its even firing. Its not.
Anything I’m missing here ?


import { fetch } from "wix-fetch";
import wixData from 'wix-data';
// import wixStores from 'wix-stores';
import wixStores from 'wix-stores-backend';

export function wixStores_onCartCreated(event) {
 let total = event.totals.total;
 console.log("cart event fired");
 wixData.insert('backendLog', {'title': total});
}