"use server";
import { prisma, Prisma } from "@repo/db";

export const addMessage = async (notam: Prisma.NotamCreateInput) => {
	try {
		await prisma.notam.create({
			data: notam,
		});
	} catch (error) {
		throw new Error("Failed to add message");
	}
};

export const disableMessage = async () => {
	try {
		await prisma.notam.create({
			data: {},
		});
	} catch (error) {
		throw new Error("Failed to disable message");
	}
};
