core&framework: pass type checks on cordis 4.0.0-alpha.1

This commit is contained in:
undefined committed 2025-03-04 09:49:54 +08:00
1 parent 2c8c03153e
commit bd63331137
13 files changed
+100 -64

No files matched your search

+1 -2
View File
@@ -1,7 +1,6 @@
import type { HandlerCommon } from './server';
import type { Context } from '@cordisjs/core';
export default function serializer<T extends Context>(ignoreSerializeFunction = false, h?: HandlerCommon<T>) {
export default function serializer<T>(ignoreSerializeFunction = false, h?: HandlerCommon<T>) {
return (k: string, v: any) => {
if (k.startsWith('_') && k !== '_id') return undefined;
if (typeof v === 'bigint') return `BigInt::${v.toString()}`;