Started deleting of ads.
This commit is contained in:
@@ -152,13 +152,17 @@ const notifyForNewAdPublish = async (realEstate, kiviOriginal) => {
|
||||
// console.log("Real estate:", realEstate);
|
||||
// console.log("Kivi original:", kiviOriginal);
|
||||
const email = kiviOriginal.dataValues.email;
|
||||
const emailSubject = `${stagingTag}Kivi: Uspješno ste objavili oglas!`;
|
||||
const emailSubject = `${stagingTag}Kivi - Uspješno ste objavili oglas!`;
|
||||
const matches = await matchRealEstates([realEstate]);
|
||||
|
||||
const numberOfMatchingRequests = Object.keys(matches).length;
|
||||
//Counting number of matching req
|
||||
let numberOfMatchingRequests = 0;
|
||||
for (const match in matches) {
|
||||
numberOfMatchingRequests++;
|
||||
}
|
||||
|
||||
const emailContent = generateNewAdPublishEmail(
|
||||
realEstate,
|
||||
kiviOriginal,
|
||||
numberOfMatchingRequests
|
||||
);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user