Compare commits

..

3 Commits

Author SHA1 Message Date
445801941d fix 2026-03-27 17:59:59 +08:00
defafe694f chore(release): 1.7.3 2026-03-27 17:22:38 +08:00
cd3a9cc223 Fix server
### Issue:  process.listenerCount()
2026-03-13 16:44:25 +08:00
4 changed files with 15 additions and 11 deletions

View File

@@ -2,6 +2,8 @@
All notable changes to this project will be documented in this file. See [commit-and-tag-version](https://github.com/absolute-version/commit-and-tag-version) for commit guidelines.
## [1.7.3](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.7.2...v1.7.3) (2026-03-27)
## [1.7.2](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.7.1...v1.7.2) (2026-03-13)
## [1.7.1](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.7.0...v1.7.1) (2026-03-11)

View File

@@ -1,6 +1,6 @@
{
"name": "hipmi",
"version": "1.7.2",
"version": "1.7.3",
"private": true,
"prisma": {
"seed": "bun prisma/seed.ts"

View File

@@ -2,7 +2,10 @@ import _ from "lodash";
import { NextResponse } from "next/server";
import prisma from "@/lib/prisma";
import { sendNotificationMobileToManyUser } from "@/lib/mobile/notification/send-notification";
import { NotificationMobileBodyType, NotificationMobileTitleType } from "../../../../../types/type-mobile-notification";
import {
NotificationMobileBodyType,
NotificationMobileTitleType,
} from "../../../../../types/type-mobile-notification";
import { routeUserMobile } from "@/lib/mobile/route-page-mobile";
export { POST, GET };
@@ -72,15 +75,9 @@ async function GET(request: Request) {
const search = searchParams.get("search");
const category = searchParams.get("category");
const page = searchParams.get("page");
const takeData = 5;
const takeData = 10;
const skipData = (Number(page) - 1) * takeData;
// console.log("authorId", authorId);
// console.log("userLoginId", userLoginId);
// console.log("search", search);
// console.log("category", category);
console.log("page", page);
try {
if (category === "beranda") {
const blockUserId = await prisma.blockedUser

View File

@@ -46,9 +46,14 @@ async function gracefulShutdown(): Promise<void> {
}
// Register shutdown handlers (hanya di environment Node.js)
// Cegah duplikasi listener dengan cek listenerCount terlebih dahulu
if (typeof process !== "undefined") {
process.on("SIGINT", gracefulShutdown);
process.on("SIGTERM", gracefulShutdown);
if (process.listenerCount("SIGINT") === 0) {
process.on("SIGINT", gracefulShutdown);
}
if (process.listenerCount("SIGTERM") === 0) {
process.on("SIGTERM", gracefulShutdown);
}
}
export default prisma;