appwrite-utils-cli 1.2.27 → 1.2.28
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.
@@ -335,12 +335,12 @@ export const createOrUpdateAttribute = async (db, dbId, collection, attribute) =
|
|
335
335
|
case "double":
|
336
336
|
case "float": // Backward compatibility
|
337
337
|
if (action === "create") {
|
338
|
-
await tryAwaitWithRetry(async () => await db.createFloatAttribute(dbId, collection.$id, finalAttribute.key, finalAttribute.required || false, finalAttribute.min
|
338
|
+
await tryAwaitWithRetry(async () => await db.createFloatAttribute(dbId, collection.$id, finalAttribute.key, finalAttribute.required || false, finalAttribute.min !== undefined ? finalAttribute.min : -2147483647, finalAttribute.max !== undefined ? finalAttribute.max : 2147483647, finalAttribute.xdefault !== undefined && !finalAttribute.required
|
339
339
|
? finalAttribute.xdefault
|
340
340
|
: null, finalAttribute.array || false));
|
341
341
|
}
|
342
342
|
else {
|
343
|
-
await tryAwaitWithRetry(async () => await db.updateFloatAttribute(dbId, collection.$id, finalAttribute.key, finalAttribute.required || false, finalAttribute.min
|
343
|
+
await tryAwaitWithRetry(async () => await db.updateFloatAttribute(dbId, collection.$id, finalAttribute.key, finalAttribute.required || false, finalAttribute.min !== undefined ? finalAttribute.min : -2147483647, finalAttribute.max !== undefined ? finalAttribute.max : 2147483647, finalAttribute.xdefault !== undefined && !finalAttribute.required
|
344
344
|
? finalAttribute.xdefault
|
345
345
|
: null));
|
346
346
|
}
|
package/package.json
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "appwrite-utils-cli",
|
3
3
|
"description": "Appwrite Utility Functions to help with database management, data conversion, data import, migrations, and much more. Meant to be used as a CLI tool, I do not recommend installing this in frontend environments.",
|
4
|
-
"version": "1.2.
|
4
|
+
"version": "1.2.28",
|
5
5
|
"main": "src/main.ts",
|
6
6
|
"type": "module",
|
7
7
|
"repository": {
|
@@ -552,8 +552,8 @@ export const createOrUpdateAttribute = async (
|
|
552
552
|
collection.$id,
|
553
553
|
finalAttribute.key,
|
554
554
|
finalAttribute.required || false,
|
555
|
-
finalAttribute.min
|
556
|
-
finalAttribute.max
|
555
|
+
finalAttribute.min !== undefined ? finalAttribute.min : -2147483647,
|
556
|
+
finalAttribute.max !== undefined ? finalAttribute.max : 2147483647,
|
557
557
|
finalAttribute.xdefault !== undefined && !finalAttribute.required
|
558
558
|
? finalAttribute.xdefault
|
559
559
|
: null,
|
@@ -568,8 +568,8 @@ export const createOrUpdateAttribute = async (
|
|
568
568
|
collection.$id,
|
569
569
|
finalAttribute.key,
|
570
570
|
finalAttribute.required || false,
|
571
|
-
finalAttribute.min
|
572
|
-
finalAttribute.max
|
571
|
+
finalAttribute.min !== undefined ? finalAttribute.min : -2147483647,
|
572
|
+
finalAttribute.max !== undefined ? finalAttribute.max : 2147483647,
|
573
573
|
finalAttribute.xdefault !== undefined && !finalAttribute.required
|
574
574
|
? finalAttribute.xdefault
|
575
575
|
: null
|