import AppError from "../../errors/AppError"; import SchedulingNotify from "../../models/SchedulingNotify"; const DeleteSchedulingNotifyService = async (id: string | number): Promise => { const schedulingNotify = await SchedulingNotify.findOne({ where: { id } }); if (!schedulingNotify) { throw new AppError("ERR_NO_SCHEDULING_NOTIFY_FOUND", 404); } await schedulingNotify.destroy(); }; export default DeleteSchedulingNotifyService;