gusfune
07/22/2021, 6:01 AMERR_HEADERS ALREADY SENT
and we figured the cultprit was our session refresher in this session, as it was refreshing the session and still trying to send the data back to the user.
We were using supertokens.errorHandler()(error, req, res, () => ({}))
in the function for this.
If we remove this, the already sent errors are gone, but if an user is logged for too long , the session refresh will cause some collateral effects (require a page refresh), but still, it's not nice. Any idea how we can refresh the session or if we should just drop the request if it's a refresher?