
export function sendError(thMsg = 'เกิดข้อผิดพลาดไม่คาดคิดเกิดขึ้น', enMsg = 'Unexpected error', code = 400, data = []) {
  return {
    code: String(code),
    message: enMsg,
    message_th: thMsg,
    data: data
  }
}

export function formatSuccessResponse(data) {
  return {
    code: "200",
    message: "successful",
    message_th: "ดำเนินการสำเร็จ",
    data: data || null
  }
}