auth 1.6.21 → 1.6.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api.mjs +1 -1
- package/dist/index.mjs +1 -1
- package/package.json +5 -5
package/dist/api.mjs
CHANGED
|
@@ -133,7 +133,7 @@ const generateDrizzleSchema = async ({ options, file, adapter }) => {
|
|
|
133
133
|
if (attr.defaultValue !== null && typeof attr.defaultValue !== "undefined") if (typeof attr.defaultValue === "function") {
|
|
134
134
|
if (attr.type === "date" && attr.defaultValue.toString().includes("new Date()")) if (databaseType === "sqlite") type += `.default(sql\`(cast(unixepoch('subsecond') * 1000 as integer))\`)`;
|
|
135
135
|
else type += `.defaultNow()`;
|
|
136
|
-
} else if (typeof attr.defaultValue === "string") type += `.default(
|
|
136
|
+
} else if (typeof attr.defaultValue === "string") type += `.default(${JSON.stringify(attr.defaultValue)})`;
|
|
137
137
|
else if (Array.isArray(attr.defaultValue)) {
|
|
138
138
|
const elements = attr.defaultValue.map((value) => JSON.stringify(value)).join(", ");
|
|
139
139
|
type += `.default([${elements}])`;
|
package/dist/index.mjs
CHANGED
|
@@ -703,7 +703,7 @@ const generateDrizzleSchema = async ({ options, file, adapter }) => {
|
|
|
703
703
|
if (attr.defaultValue !== null && typeof attr.defaultValue !== "undefined") if (typeof attr.defaultValue === "function") {
|
|
704
704
|
if (attr.type === "date" && attr.defaultValue.toString().includes("new Date()")) if (databaseType === "sqlite") type += `.default(sql\`(cast(unixepoch('subsecond') * 1000 as integer))\`)`;
|
|
705
705
|
else type += `.defaultNow()`;
|
|
706
|
-
} else if (typeof attr.defaultValue === "string") type += `.default(
|
|
706
|
+
} else if (typeof attr.defaultValue === "string") type += `.default(${JSON.stringify(attr.defaultValue)})`;
|
|
707
707
|
else if (Array.isArray(attr.defaultValue)) {
|
|
708
708
|
const elements = attr.defaultValue.map((value) => JSON.stringify(value)).join(", ");
|
|
709
709
|
type += `.default([${elements}])`;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "auth",
|
|
3
|
-
"version": "1.6.
|
|
3
|
+
"version": "1.6.23",
|
|
4
4
|
"description": "The CLI for Better Auth",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -60,9 +60,9 @@
|
|
|
60
60
|
"semver": "^7.7.4",
|
|
61
61
|
"yocto-spinner": "^0.2.3",
|
|
62
62
|
"zod": "^4.3.6",
|
|
63
|
-
"@better-auth/core": "1.6.
|
|
64
|
-
"@better-auth/telemetry": "1.6.
|
|
65
|
-
"better-auth": "1.6.
|
|
63
|
+
"@better-auth/core": "1.6.23",
|
|
64
|
+
"@better-auth/telemetry": "1.6.23",
|
|
65
|
+
"better-auth": "1.6.23"
|
|
66
66
|
},
|
|
67
67
|
"devDependencies": {
|
|
68
68
|
"@types/better-sqlite3": "^7.6.13",
|
|
@@ -75,7 +75,7 @@
|
|
|
75
75
|
"tsx": "^4.21.0",
|
|
76
76
|
"type-fest": "^5.4.4",
|
|
77
77
|
"typescript": "^5.9.3",
|
|
78
|
-
"@better-auth/passkey": "1.6.
|
|
78
|
+
"@better-auth/passkey": "1.6.23"
|
|
79
79
|
},
|
|
80
80
|
"scripts": {
|
|
81
81
|
"build": "tsdown",
|