const { sendMessage } = require('../api');
const { safeExec } = require('../helpers');

const sendNotification = safeExec(async (chatId, title, body) => {
  const msg = `🔔 <b>${title}</b>\n${body}`;
  await sendMessage(chatId, msg);
});

module.exports = { sendNotification };
