Refactor user verification and data handling
All checks were successful
Build and Push Docker Images / Build and Push Docker Images (push) Successful in 55s

- Updated `package.json` to add a new script for Prisma database setup.
- Replaced `usePerson` hook with `getNationalPerson` function in `lib/person.ts` for improved national data fetching.
- Refactored imports in `auth-actions.ts`, `user-actions.ts`, and `verify/page.tsx` to use the new `getNationalPerson` function.
- Enhanced device notification logic in `check-devices/route.ts` to correctly handle payment data.
- Improved error handling in `devices-to-pay.tsx` for better user feedback.

These changes streamline user verification processes and enhance data integrity across the application.
This commit is contained in:
2025-01-10 21:58:13 +05:00
parent fcf4f37561
commit a3f0759731
8 changed files with 37 additions and 34 deletions

View File

@ -110,8 +110,8 @@ export default function DevicesToPay({
case res?.success === true:
toast.success(res.message);
break;
case res.success === false:
toast.error(res.message);
case res?.success === false:
toast.error(res?.message);
break;
default:
toast.error("Unexpected error occurred.");