auth 1.7.0-rc.0 → 1.7.0-rc.1
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
|
@@ -142,7 +142,7 @@ const generateDrizzleSchema = async ({ options, file, adapter }) => {
|
|
|
142
142
|
if (attr.defaultValue !== null && typeof attr.defaultValue !== "undefined") if (typeof attr.defaultValue === "function") {
|
|
143
143
|
if (attr.type === "date" && attr.defaultValue.toString().includes("new Date()")) if (databaseType === "sqlite") type += `.default(sql\`(cast(unixepoch('subsecond') * 1000 as integer))\`)`;
|
|
144
144
|
else type += `.defaultNow()`;
|
|
145
|
-
} else if (typeof attr.defaultValue === "string") type += `.default(
|
|
145
|
+
} else if (typeof attr.defaultValue === "string") type += `.default(${JSON.stringify(attr.defaultValue)})`;
|
|
146
146
|
else if (Array.isArray(attr.defaultValue)) {
|
|
147
147
|
const elements = attr.defaultValue.map((value) => JSON.stringify(value)).join(", ");
|
|
148
148
|
type += `.default([${elements}])`;
|
package/dist/index.mjs
CHANGED
|
@@ -1419,7 +1419,7 @@ const generateDrizzleSchema = async ({ options, file, adapter }) => {
|
|
|
1419
1419
|
if (attr.defaultValue !== null && typeof attr.defaultValue !== "undefined") if (typeof attr.defaultValue === "function") {
|
|
1420
1420
|
if (attr.type === "date" && attr.defaultValue.toString().includes("new Date()")) if (databaseType === "sqlite") type += `.default(sql\`(cast(unixepoch('subsecond') * 1000 as integer))\`)`;
|
|
1421
1421
|
else type += `.defaultNow()`;
|
|
1422
|
-
} else if (typeof attr.defaultValue === "string") type += `.default(
|
|
1422
|
+
} else if (typeof attr.defaultValue === "string") type += `.default(${JSON.stringify(attr.defaultValue)})`;
|
|
1423
1423
|
else if (Array.isArray(attr.defaultValue)) {
|
|
1424
1424
|
const elements = attr.defaultValue.map((value) => JSON.stringify(value)).join(", ");
|
|
1425
1425
|
type += `.default([${elements}])`;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "auth",
|
|
3
|
-
"version": "1.7.0-rc.
|
|
3
|
+
"version": "1.7.0-rc.1",
|
|
4
4
|
"description": "The CLI for Better Auth",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -64,9 +64,9 @@
|
|
|
64
64
|
"semver": "^7.8.4",
|
|
65
65
|
"yocto-spinner": "^1.2.0",
|
|
66
66
|
"zod": "^4.3.6",
|
|
67
|
-
"@better-auth/core": "1.7.0-rc.
|
|
68
|
-
"@better-auth/telemetry": "1.7.0-rc.
|
|
69
|
-
"better-auth": "1.7.0-rc.
|
|
67
|
+
"@better-auth/core": "1.7.0-rc.1",
|
|
68
|
+
"@better-auth/telemetry": "1.7.0-rc.1",
|
|
69
|
+
"better-auth": "1.7.0-rc.1"
|
|
70
70
|
},
|
|
71
71
|
"devDependencies": {
|
|
72
72
|
"@types/better-sqlite3": "^7.6.13",
|
|
@@ -78,7 +78,7 @@
|
|
|
78
78
|
"tsx": "^4.21.0",
|
|
79
79
|
"type-fest": "^5.7.0",
|
|
80
80
|
"typescript": "^5.9.3",
|
|
81
|
-
"@better-auth/passkey": "1.7.0-rc.
|
|
81
|
+
"@better-auth/passkey": "1.7.0-rc.1"
|
|
82
82
|
},
|
|
83
83
|
"scripts": {
|
|
84
84
|
"build": "tsdown",
|