I have a string and want to match:
await Listing.find({
Test: 1
});
But don’t want to match it if it ends with .lean();
await Listing.find({
Test: 1
}).lean();
I have this regex but it’s not working:
(?<=await)([\S\s]*?)(?!.+\.lean())(;)