fix: null bigint error

This commit is contained in:
DIYgod
2024-10-18 19:34:46 +08:00
parent 8f567b1321
commit fa2d0f3583
3 changed files with 2 additions and 21 deletions
+1 -1
View File
@@ -20,7 +20,7 @@ export const Balance = ({
withSuffix?: boolean
withTooltip?: boolean
}) => {
const n = [BigInt(children) || BigInt(value || 0n), 18] as const
const n = [BigInt(children || 0n) || BigInt(value || 0n), 18] as const
const formatted = format(n, { digits: precision, trailingZeros: true })
const formattedFull = format(n, { digits: 18, trailingZeros: true })
+1
View File
@@ -23,6 +23,7 @@
"4002": "Insufficient balance",
"4003": "Feed insufficient withdrawable balance",
"4004": "Target user wallet error",
"4005": "Daily power calculation in progress",
"5000": "Invitation limit exceeded. Please try again in a few days.",
"5001": "Invitation already exists.",
"5002": "Invitation code already used.",
-20
View File
@@ -4365,22 +4365,6 @@ declare const levels: drizzle_orm_pg_core.PgTableWithColumns<{
baseColumn: never;
generated: undefined;
}, {}, {}>;
statusUpdatedAt: drizzle_orm_pg_core.PgColumn<{
name: "status_updated_at";
tableName: "levels";
dataType: "date";
columnType: "PgTimestamp";
data: Date;
driverParam: string;
notNull: false;
hasDefault: false;
isPrimaryKey: false;
isAutoincrement: false;
hasRuntimeDefault: false;
enumValues: undefined;
baseColumn: never;
generated: undefined;
}, {}, {}>;
powerToken: drizzle_orm_pg_core.PgColumn<{
name: "power_token";
tableName: "levels";
@@ -4422,7 +4406,6 @@ declare const levelsOpenAPISchema: zod.ZodObject<{
level: zod.ZodNullable<zod.ZodNumber>;
prevActivityPoints: zod.ZodNullable<zod.ZodNumber>;
activityPoints: zod.ZodNullable<zod.ZodNumber>;
statusUpdatedAt: zod.ZodNullable<zod.ZodString>;
powerToken: zod.ZodString;
userId: zod.ZodString;
}, zod.UnknownKeysParam, zod.ZodTypeAny, {
@@ -4433,7 +4416,6 @@ declare const levelsOpenAPISchema: zod.ZodObject<{
level: number | null;
prevActivityPoints: number | null;
activityPoints: number | null;
statusUpdatedAt: string | null;
}, {
userId: string;
address: string;
@@ -4442,7 +4424,6 @@ declare const levelsOpenAPISchema: zod.ZodObject<{
level: number | null;
prevActivityPoints: number | null;
activityPoints: number | null;
statusUpdatedAt: string | null;
}>;
declare const levelsRelations: drizzle_orm.Relations<"levels", {
wallet: drizzle_orm.One<"wallets", true>;
@@ -5149,7 +5130,6 @@ declare const _routes: hono_hono_base.HonoBase<Env, {
level: number | null;
prevActivityPoints: number | null;
activityPoints: number | null;
statusUpdatedAt: string | null;
}[];
};
outputFormat: "json" | "text";